New MacBook to have glass trackpad (End of September)

Source
http://blogs.computerworld.com/rumor_macbook_updates_to_include_glass_trackpad_other_goodies

I've got to say the multi-touch glass screen on the iPhone is pretty neat - and I've seen the multi-tracking trackpad on the macbook.  Trisnadi Kurniawan (we call him Tristan) owns one.  Couple of other guys in the office already have, or are getting their MacBooks soon and dual boots daily.

Personally I'm still not convinced the MacBook is worth twice the cost of other notebooks such as offerings from Dell, Acer or Asus.  A typical dual-core laptop with 4GB ram and readyboost should be able to handily out perform a MacBook any day.

But anyway, with all the chatter about touch trackpads, here's my prediction for 2010:

 

Year 2010, Steve Jobs unveils the MacBook Super Touch Pro.  There is no keyboard or trackpad for this MacBook, the touch keyboard functions as:

  • on screen keyboard + trackpad
  • artpad
  • finger print scanner
  • a numeric keypad is available and slides in from the right (or left-hand) with a simple swipe gesture
  • additional keys can be added and removed from the virtual keyboard
  • keys can be resized.  commonly used keys have a slightly larger detect surface - but you won't see it because SteveJ would rather die than to show a keyboard with non-identical-sized keys.
  • the keyboard is backlit (or how else would you be able to see the keys)
  • There is no gap between the keys so dirt can't get in
  • Water / coffee resistant
  • The thickness of the MacBook is further reduced down to 2cm.  Making this the Thinnest Laptop Ever (tm).
  • The MacBook dissipates some of the heat via the glass keyboard panel so it keeps your hands warm in the winter.
  • The two areas where the palm rests can be configured to show your todo-list, mail inbox, ipod play list, or photos of your loved ones (defaults to your idol SteveJ of course).

In other news, Microsoft complained that this was the same surface technology they've demo'ed 5 years ago in 2005 (but never worked out how to sell it properly).

In yet more other news, Homer complains that he can no longer use the drinking bird to press the Y-key on his MacBook.  Because the keyboard detects human touch only.

jliu

HTML map and area tags not working for FireFox

Here was an interesting problem, what was wrong with the following code, which works fine in IE but not in FireFox

<map id="mymap">
<area ... />
<area ... />
</map>

<img usemap="#mymap" ...>


It appears that FireFox doesn't understand the id attribute and the name attribute is required.  According to W3C recommendations, http://www.w3.org/TR/REC-html40/struct/objects.html#adef-usemap the usemap attribute should match the name attribute of the map tag.

Try this instead:

<map id="mymap" name="mymap">

Customizing CSSLink and ScriptLink for public Sharepoint site

MSDN has quite a thorough topic on optimizing a Sharepoint Server for public facing site:

http://msdn.microsoft.com/en-us/library/bb727371.aspx

I would just like to add a few more points and share some thoughts on our experiences of customizing for performance in addition to this guide.

  1. Design your Sharepoint website with performance in mind.  If you had it as an after thought and think "ooh, I'll just add performance bits at the end", then your options are far more limited.  Not to mention the extra testing time you'll need.  If you are in this situation, I'd say just stick with the caching options.
  2. Most visitors to a public facing site would be anonymous users - in fact, only a very small percentage of people may actually want to modify the website.  So switch on anonymous login and start your optimizations there
  3. The easiest bits to set up are the caching options for Sharepoint.  Sharepoint Server 2007 provides 3 means of caching:
    1. Page Output Caching - this is basically ASP.NET output caching, wrapped within Sharepoint.  Follow the discussion in the article above will get you sorted.  This has the biggest performance improvement for large amount of anonymous visitors.
    2. Object Caching - this is Sharepoint caching recently accessed object's properties (and lists) so that Sharepoint doesn't have to re-access them from Database.
    3. Binary Large Objects (BLOB) caching - this is Sharepoint caching large objects that are otherwise stored in the database on a file server.  Things like pictures, javascript files, audio, SilverLight, Flash, movies, etc.  This has to be set via the web.config (defaults to 10 GB of space allocated for this).
    4. OK, these are the easy stuff - read the MSDN link if you need instructions to set this up.
  4. The article further discusses rendering core.js for only authenticated users.  This takes a bit more effort to figure out.
    1. The idea behind the RegisterCoreWhenAuthenticatedControl is good, but proper implementation requires understanding of how ScriptLink works.
    2. A ScriptLink control can be specified on the page at one point, and subsequent ScriptLink.Register will add more scripts to be added at that point.
    3. A ScriptLink control will always register core.js unless it is in minimal mode
    4. To create a ScriptLink in minimal mode, create one in the markup without the name attribute (yes.  this is really cryptic - here's why you need Reflector)
    5. <Sharepoint:ScriptLink runat="server"/>
    6. Follow by the control specified in the article:
    7. <NoCoreLoad:RegisterCoreWhenAuthenticatedControl runat="server"/>
  5. We took the idea a bit further and thought if we can get rid of the core.js file, how about get rid of the core.css file too, or in fact, anything.  What we need is a wrapper container of some sort.
    1. There are two related classes for CssLink
    2. The CssRegistration class adds CSS files to the Sharepoint context
    3. The CssLink control renders all CSS files added to the Sharepoint context
    4. The CssLink can have additional DefaultUrl and AlternativeUrl specified,  but it will always render the core.css file.  There is no minimal mode
    5. The way we use is to create a wrapper container for CssLink

      public class AuthenticatedPanel : Panel
      {
          protected override void Render(HtmlTextWriter writer)
          {
              if (HttpContext.Current.Request.IsAuthenticated)
              {
                  base.Render(writer);
              }
          }
          public override void RenderBeginTag(HtmlTextWriter writer)
          {
              //disable rendering <div>
              //base.RenderBeginTag(writer);
          }
          public override void RenderEndTag(HtmlTextWriter writer)
          {
              //disable rendering </div>
              //base.RenderEndTag(writer);
          }
      }
    6. <AuthenticatedPanel>
          <CssLink runat="server"/>
          <CssRegistration runat="server ... />
      </AuthenticatedPanel>

      <link rel="stylesheet" type="text/css" href="...path" />
  6. I like the AuthenticatedPanel that we created a lot more than the RegisterCoreWhenAuthenticatedControl - it is far more flexible in terms of the control we get on what gets rendered on the page at the end.

Good luck!

The best way to learn to customizing Sharepoint for an ASP.NET guy - use Reflector

This is probably the best best tip I'm going to share so far with regards to Sharepoint.

Think of Sharepoint as a pre-built framework on top of ASP.NET, if you are working within the confines of the multitude of options Sharepoint gives you, then you need a big thick book on Sharepoint.

If you are thinking about customizing Sharepoint, then you're beginning to face a problem I had.

How does it all work, and perhaps more importantly, why does it just not work?

You can resort to Google.  In which case, I hope you find this blog.

Or you can grab Reflector and peek inside the secrets of Microsoft.Sharepoint (WSS) and Microsoft.Sharepoint.Publishing (MOSS) assemblies.

I'll share with some findings real soon.

Tough to love Sharepoint

Recently started doing some work on Sharepoint, it's really tough to love Sharepoint.

At a glance, it seems that this is just a technology that's build on top of ASP.NET, so surely it's got all the goodness of ASP.NET + more build-in goodness.

Actually, I'd almost say it's the opposite.

It's got all the goodness of ASP.NET locked away where you can't easily use to customize your solution.

So if you are after something out of the box with light modifications, Sharepoint is really your friend.

As soon as you want heavy modifications, it feels like a complete road block.

Still, it has some really great publishing features, which distinctively makes it very compelling for an enterprise to use and set up.

I'll have more to say very soon.