Category Archives: New Stuff

News about site and in general

Infragistics WebDataMenu: Expanding context menu UP

Infragistics WebDataMenu is a light-weight highly responsive menu control with rich server and clinet side model. I was using it to display context menu on right mouse click.  The code is pretty simple:

function onMouseClick(oEvent) {
   if (oEvent.button == 2) { //right mouse button clicked
      var menu = $find("xwdmMyMenu");
      menu.showAt(null,null, oEvent);
   }
}

It checks whether the right mouse button was clicked (line 2) then locates the menu object and shows it using showAt method (which accepts 3 parameters, either X and Y client coordinates, or event object from which it derives coordinates of the mouse click).

 It’s all well and good, but the problem is – menu always shows down from the location of the mouse click. And if the click is at the bottom of the screen – menu gets cut off:

I needed to make menu expand UP and  couldn’t find a build-in property or method that would change this behaviour (GroupSettings.ExpandDirection property had no effect). Time for a little hack. Continue reading →

Take a friv break

Tired of all that coding? Take a well deserved break with this fine site, filled with 250+ Flash games combined into unusual one-screen interface:
Friv
So go ahead, visit http://www.friv.co.uk, but heed this warning: many of the games require non-trivial thinking (not to mention they’re highgly addictive).

Infragistics Drag and Drop: detecting element during drag

I was using Infragistics drag-and-drop framework and set an HTML table element as my drop target. Now I needed to know during drag operation over which HTML table cell I am moving. I needed that in order to dynamically change appearance of draggable markup depending on which cell I am currently over.



(Think a strategy game – you’re placing construction on the terrain – if there is enough unoccupied room – the draggable item becomes green, otherwise it remains red).

The solution is to use elemAtPoint property during DragMoveHandler event. Continue reading →

Windows 7: First Impressions

I’ve been using Windows 7 Release Candidate for about a week and so far like it very much. Out of all Oses I’ve ever installed it was the first one to detect my home wireless network during setup. Oh and under Windows 7 for the first time Intel Wireless N card achieved full 300Mbps speed even though it is connected to a Dlink router (all manufacturers warn that to achieve full N speed you have to have both client and access point of the same brand). And overall it has a very light, easy feeling, I actually enjoy sitting behind Aero desktop. And only now in comparison, I understand what a bloated pressure was imposed by Vista behemoth.

No compatibility issues, all software and games work perfectly (by the way I am using 64-bit version of Windows 7). It looks like Microsoft did good this time. Apparently Windows releases follow the same law as Star Trek movies – every odd one sucks, every even one is good:

  • Windows 95 – weak start
  • Windows 98 – ok
  • Windows Me – sucked big time
  • Windows XP – pretty good
  • Windows Vista – big flop
  • Windows 7 – … so far so good

So hopefully Windows 7 will be a hit, as well as the new Star Trek movie (which I still have to see).

Changing hosting

When I got my $300 hosting bill today – it was a last straw. $120 a year for 100Mb in a single MySQL database, nessessity of a dedicated IP address simple so I could  use subdomains (another $60),  a gig of space and 80 gig monthly transfer for another $120 – thank you, but no, thank you.

Goodby DiscountASP, hello BlueHost.