Blog Archives

Battery Technology in the 17″ Macbook Pro

Posted in Product Reviews

There are five developers here at The Frontier Group and four of us have partners. That’s nine people, between them there are eight Apple laptops of various vintages. Five of them are our own Macbook Pros. If you were to say that we are impressed with Apple products and enjoy using them daily then I’d say you are dead right!

Apple have recently released their new 17″ Macbook Pro and have given it an embedded, non-removable battery pack. On initial impression this seems to be quite a limitation. In reality given that they are touting 8 hours of battery life and 1000 recharges the battery could quite legitimately last 2-3 years of even the most heavy use.

Their video detailing why they went with an embedded battery and how the battery pack is manufactured is pretty interesting. It explains how the batteries are manufactured and where they saved space and weight as well as the improvements they made to increase the lifespan of the battery pack.

My assumption is that the battery is replaceable, it’s just that you’ll need to take it to a service centre to have it done. They don’t seem to mention this on the website though so I may be wrong.

If the battery is truly and completely irreplaceable then I think their claims of environmental friendliness and so on would be debunked. I guess we’ll hear about it in a couple of years time.

All in all though I’m pretty excited about the new Macbook Pro and after having seen one in the flesh at work I’m keen to see one in my own hands some time this year or next.

UPDATE : According to Gizmodo the battery is replaceable after all for US$179. To me that seems like an entirely reasonable price if the battery life lives up to the claims.

Animating Table Rows with jQuery

Posted in AuroraCMS, Code, Product Reviews, Tips and Tricks

Animating table rows in the browser is problematic. You see, they aren’t block elements and as such don’t have a height or width property. Instead they take their constraints from the content inside them, and the elements that contain them. For rows this typically means they’re constrained by the containing table, and filled by the contained columns.

Today I wanted to slide a row up, and then when it had finished sliding I wanted to remove it from the DOM. Essentially giving it a nice effect when something is deleted.

Given that the height of a row is controlled by it’s content, I figured the easiest way to do this would be to wrap all of the content inside each column with a block element, in this case a div, and then resize those.

jQuery makes this extremely easy :

var el = $(options.element_prefix + id);
el.children("td").each(function() {
    $(this).wrapInner("< div />").children("div").slideUp(function() {el.remove();})
});

NOTE : The div tag in the wrapInner() is malformed because it won’t display properly otherwise. Please remove the space between the opening bracket and ‘div’.

It’s all pretty easy to understand. Essentially my root element is a row, and so for each td in that row wrap it’s content in a div. Then for the child divs in each td, run the slideUp() method. The callback in the slideUp() method says after the animation is done, remove the row. Given the speed of computers these days, no one will notice that the last few columns quite likely just vanish instead of complete their animation.

MySQL IDE for OS X

Posted in Product Reviews, Websites or Tools

I came from a Microsoft background, when I was there I complained about some aspects of it, but in hindsight one thing I miss a lot is a good IDE for SQL and database related development. SQL server didn’t have anything amazing, but it did the job and was stable.

I’m a big believer in visualisation and easy visualisation when working with data. It’s there to be used and if you can’t visualise it simply, if you can muck around with it and fiddle and massage it into various shapes and sizes easily then it’s more likely to be left alone. Data that’s left to rot is like leaving gold to rust. If gold rusted.

In short data is valuable, but only if it’s used.

In my quest for tools I’ve tried a few and found none that I would actually pay for, except the one I’ve been using now for a couple of months without a problem. DBVisualiser Free edition, I’d pay for that. It’s lucky too because they make a paid version with a bunch of extra features.

I’m always on the lookout for better applications to improve my performance and more importantly my enjoyment at work. So far this has been the closest application I’ve found to make MySQL a joy to use on the Mac. The free version does 99% of what I want to do, the pro version just seems to add features to make life even easier.

I’d urge people working with a database on the Mac to give DBVisualiser a try.

What’s New in Rails 2.2?

Posted in Code, Product Reviews, Ruby on Rails

Last week Gregg Pollack from the Rails Envy Podcast put out the call on Twitter for reviews of their latest product, the Ruby on Rails 2.2 Envycast. I was happy to oblige and had been looking forward to checking out their unique take on screen casting for a while. Here’s what I thought.

Is it really a screen cast?

Firstly, I don’t even know if it’s correct to call it a screen cast. The viewer is not presented with a computer screen once during the 44 minute presentation. Most screen casts record the presenter’s computer desktop and have an audio commentary to accompany the video. Gregg and Jason have instead gone the “weather-man” approach and are using a green-screen as their canvas. This has some immediate benefits, but also has some downsides.

It develops the duo as the “face” of Envycasts. I first learnt of them through their audio podcast but they’ve done video before. I think this is important as it presents a teacher-student situation, and I’d expect there’s a bunch of psychology proving why face-to-face teaching succeeds. I think it works well for them, but would expect that other tech-screen casters might not be as comfortable in front of the camera.

The green-screen also allows them to manipulate the background as they see fit. For the viewer of this episode that means you’ll be treated to a world tour as they “travel” to various capital cities around the globe. It allows them to use their unique style of humour with ease too. I actually laughed out loud at a few moments, and enjoyed thembeing chased by the large ball of yarn in particular.

More importantly though, the green-screen also means that transition effects and attention-grabbing techniques (like exploding or rotating text) can direct your attention to the exact part of the code they’re discussing.

By not filming a mouse-cursor style screencast they’ve chosen to give up the opportunity to pass on subtle information outside of the scope of the specific topic that viewers might find useful. What do I mean? I’ve picked up on keyboard shortcuts or other techniques people use in their day-to-day programming by watching traditional screencasts. The best example I’ve found of this is Ryan Bates’ excellent Railscasts. I liken it to looking over the shoulder of a seasoned developer – you’ll pick up on nuances which are sometimes just as interesting.

Both Gregg and Jason speak clearly and are presenters that I enjoyed viewing. As an Australian, I didn’t find their accents overpowering in anyway.

It’s all about the content

The actual content is conveniently split into chapters (I viewed the 260MB MOV) which makes navigating between topics easy. I viewed the video on both a MacBook Pro laptop and 42″ plasma. I found the colours sometimes a little dark on the laptop but didn’t have the same issues on the plasma display. I suspect that my colourblindness was to blame :)

I would have appreciated a wide-screen format for the plasma, though I presume that the majority of viewers are watching on a computer screen.

The content is broken into the following seven sections:

  • ActiveRecord
  • ActiveSupport
  • ActionPack
  • ActionController
  • Railties
  • Internationalization
  • Performance

The 38 minutes (85%) are spent focussing on the code-heavy components which make up the changes to Rails 2.2. The examples given are very clear and consistent across the sections and I found the afore-mentioned transition effects helpful at tracking the exact part of the code the presenter was discussing. Your eyes are drawn to the moving parts of the code. Because you’re looking at Ruby code there’s nothing that will hurt your brain, or eyes.

The last few minutes in the presentation are spent discussing the other things that have changed with Rails 2.2 in details beyond just code examples. I enjoyed Jason explaining why gems are preferred over plugins, and Gregg’s explanation of etags and how they’ve changed in Rails 2.2 was fantastic.

Wrapping up

I was skeptical that this format would would for a such a technical topic but I’m glad to say they boys pulled it off. Their lame jokes are sometimes actually funny, though I think I’ve heard enough about Rails not scaling to last me a lifetime :)

My final thought: above all else they jammed a stack of detail into an easily-digestible format that was entertaining and informative. If you’re working with Rails then you really should be checking this out.

You can buy this Envycast along with the accompanying PDF online for just US$16, which even when you consider the current global economic situation is still a steal.

Disclaimer: The Frontier Group was provided with a free copy of this Envycast for review.

Search Posts

Featured Posts

Categories

Archives

View more archives