Changeset 152 for trunk/src


Ignore:
Timestamp:
Jun 16, 2009, 12:06:23 AM (16 years ago)
Author:
lpino
Message:
  • Macro
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/plugins/org.eclipse.swt/Eclipse SWT PI/pm/org/eclipse/swt/internal/pm/OS.java

    r150 r152  
    21802180
    21812181public static final short SHORT1FROMMP (int mp) { return (short)mp; }   
    2182 public static final short SHORT2FROMMP (int mp) { return (short)(mp >> 16); }
     2182public static final short SHORT2FROMMP (int mp) { return (short)(((mp & 0xFFFF0000)>>16) & 0xFFFF); }
     2183//((pixels & 0xFFFF0000)>>16) & 0xFFFF
    21832184//public static final int MPFROM2SHORT(short s1, short s2){ return (((int)((short)s1)) | ((int)((short)s2)) << 16);}
    21842185public static final int MPFROM2SHORT(short s1, short s2){ return ((s2 << 16) + s1);}
Note: See TracChangeset for help on using the changeset viewer.