diff options
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets')
38 files changed, 956 insertions, 956 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Button.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Button.java index c03fa48bcc..5a4010bc88 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Button.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Button.java @@ -135,7 +135,7 @@ public void addSelectionListener(SelectionListener listener) { addListener(SWT.DefaultSelection,typedListener); } -NSSize cellSizeForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSSize cellSizeForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { NSSize size = super.cellSizeForBounds(id, sel, cellFrame); if (image != null && ((style & (SWT.CHECK|SWT.RADIO)) !=0)) { NSSize imageSize = image.handle.size(); @@ -161,7 +161,7 @@ NSSize cellSizeForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { NSAttributedString attribStr = createString(text, null, foreground, style, true, true, true); NSRect rect = attribStr.boundingRectWithSize(wrapSize, OS.NSStringDrawingUsesLineFragmentOrigin); attribStr.release(); - float /*double*/ trimHeight = size.height - titleRect.height; + double /*float*/ trimHeight = size.height - titleRect.height; size.height = rect.height; if (image != null && ((style & (SWT.CHECK|SWT.RADIO)) !=0)) { NSSize imageSize = image.handle.size(); @@ -294,7 +294,7 @@ boolean dragDetect(int x, int y, boolean filter, boolean[] consume) { return dragging; } -void drawImageWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ image, NSRect rect, int /*long*/ view) { +void drawImageWithFrameInView (long /*int*/ id, long /*int*/ sel, long /*int*/ image, NSRect rect, long /*int*/ view) { /* * Feature in Cocoa. Images touch the edge of rounded buttons * when set to small size. The fix to subclass the button cell @@ -310,7 +310,7 @@ void drawImageWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ i super.drawImageWithFrameInView(id, sel, image, rect, view); } -void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cellRect, int /*long*/ viewid) { +void drawInteriorWithFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect cellRect, long /*int*/ viewid) { if ((style & (SWT.CHECK|SWT.RADIO)) != 0 && backgroundImage != null) { fillBackground (new NSView(viewid), NSGraphicsContext.currentContext(), cellRect, -1); } @@ -318,8 +318,8 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cel if (image != null && ((style & (SWT.CHECK|SWT.RADIO)) !=0)) { NSSize imageSize = image.handle.size(); NSCell nsCell = new NSCell(id); - float /*double*/ x = 0; - float /*double*/ y = (imageSize.height - cellRect.height)/2f; + double /*float*/ x = 0; + double /*float*/ y = (imageSize.height - cellRect.height)/2f; NSRect imageRect = nsCell.imageRectForBounds(cellRect); NSSize stringSize = ((NSButton)view).attributedTitle().size(); switch (style & (SWT.LEFT|SWT.RIGHT|SWT.CENTER)) { @@ -349,7 +349,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cel } -NSRect drawTitleWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ title, NSRect titleRect, int /*long*/ view) { +NSRect drawTitleWithFrameInView (long /*int*/ id, long /*int*/ sel, long /*int*/ title, NSRect titleRect, long /*int*/ view) { boolean wrap = (style & SWT.WRAP) != 0 && text.length() != 0; if (wrap) { NSSize wrapSize = new NSSize(); @@ -380,7 +380,7 @@ boolean drawsBackground() { return background != null || backgroundImage != null; } -void drawWidget (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawWidget (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if ((style & SWT.ARROW) != 0) { NSRect frame = view.frame(); int arrowSize = Math.min((int)frame.height, (int)frame.width) / 2; @@ -541,7 +541,7 @@ boolean isDescribedByLabel () { * This will cause the on state to momentarily appear while clicking on the checkbox. To avoid this, we override [NSCell nextState] * to go directly to the desired state if we have a grayed checkbox. */ -int /*long*/ nextState(int /*long*/ id, int /*long*/ sel) { +long /*int*/ nextState(long /*int*/ id, long /*int*/ sel) { if ((style & SWT.CHECK) != 0 && grayed) { return ((NSButton)view).state() == OS.NSMixedState ? OS.NSOffState : OS.NSMixedState; } @@ -706,7 +706,7 @@ void setFont (NSFont font) { } } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { ((NSButton)view).setAttributedTitle(createString()); } @@ -872,7 +872,7 @@ public void setText (String string) { updateAlignment (); } -NSRect titleRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSRect titleRectForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { NSRect rect = super.titleRectForBounds(id, sel, cellFrame); if (image != null && ((style & (SWT.CHECK|SWT.RADIO)) !=0)) { NSSize imageSize = image.handle.size(); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Canvas.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Canvas.java index b2b5edd798..707e765b30 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Canvas.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Canvas.java @@ -58,7 +58,7 @@ Canvas () { /* Do nothing */ } -int /*long*/ attributedSubstringFromRange (int /*long*/ id, int /*long*/ sel, int /*long*/ range) { +long /*int*/ attributedSubstringFromRange (long /*int*/ id, long /*int*/ sel, long /*int*/ range) { if (ime != null) return ime.attributedSubstringFromRange (id, sel, range); return super.attributedSubstringFromRange(id, sel, range); } @@ -106,7 +106,7 @@ public Canvas (Composite parent, int style) { super (parent, style); } -int /*long*/ characterIndexForPoint (int /*long*/ id, int /*long*/ sel, int /*long*/ point) { +long /*int*/ characterIndexForPoint (long /*int*/ id, long /*int*/ sel, long /*int*/ point) { if (ime != null) return ime.characterIndexForPoint (id, sel, point); return super.characterIndexForPoint (id, sel, point); } @@ -136,7 +136,7 @@ public void drawBackground (GC gc, int x, int y, int width, int height) { drawBackground(gc, x, y, width, height, 0, 0); } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { super.drawBackground(id, context, rect); if (glcontext != null) { if (isObscured()) { @@ -144,7 +144,7 @@ void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { context.saveGraphicsState(); context.setCompositingOperation(OS.NSCompositeClear); if (visiblePath == null) { - int /*long*/ visibleRegion = getVisibleRegion(); + long /*int*/ visibleRegion = getVisibleRegion(); visiblePath = getPath(visibleRegion); OS.DisposeRgn(visibleRegion); } @@ -157,17 +157,17 @@ void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { } } -void drawRect (int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawRect (long /*int*/ id, long /*int*/ sel, NSRect rect) { if (glcontext != null && glcontext.view() == null) glcontext.setView(view); super.drawRect(id, sel, rect); } -void drawWidget (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawWidget (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; super.drawWidget (id, context, rect); if (caret == null) return; if (caret.isShowing) { - int /*long*/ ctx = context.graphicsPort(); + long /*int*/ ctx = context.graphicsPort(); OS.CGContextSaveGState (ctx); OS.CGContextSetBlendMode (ctx, OS.kCGBlendModeDifference); Image image = caret.image; @@ -182,18 +182,18 @@ void drawWidget (int /*long*/ id, NSGraphicsContext context, NSRect rect) { NSSize size = imageHandle.size(); destRect.size.width = size.width; destRect.size.height = size.height; - int /*long*/ data = rep.bitmapData(); - int /*long*/ format = rep.bitmapFormat(); - int /*long*/ bpr = rep.bytesPerRow(); + long /*int*/ data = rep.bitmapData(); + long /*int*/ format = rep.bitmapFormat(); + long /*int*/ bpr = rep.bytesPerRow(); int alphaInfo; if (rep.hasAlpha()) { alphaInfo = (format & OS.NSAlphaFirstBitmapFormat) != 0 ? OS.kCGImageAlphaFirst : OS.kCGImageAlphaLast; } else { alphaInfo = (format & OS.NSAlphaFirstBitmapFormat) != 0 ? OS.kCGImageAlphaNoneSkipFirst : OS.kCGImageAlphaNoneSkipLast; } - int /*long*/ provider = OS.CGDataProviderCreateWithData(0, data, bpr * (int)size.height, 0); - int /*long*/ colorspace = OS.CGColorSpaceCreateDeviceRGB(); - int /*long*/ cgImage = OS.CGImageCreate((int)size.width, (int)size.height, rep.bitsPerSample(), rep.bitsPerPixel(), bpr, colorspace, alphaInfo, provider, 0, true, 0); + long /*int*/ provider = OS.CGDataProviderCreateWithData(0, data, bpr * (int)size.height, 0); + long /*int*/ colorspace = OS.CGColorSpaceCreateDeviceRGB(); + long /*int*/ cgImage = OS.CGImageCreate((int)size.width, (int)size.height, rep.bitsPerSample(), rep.bitsPerPixel(), bpr, colorspace, alphaInfo, provider, 0, true, 0); OS.CGColorSpaceRelease(colorspace); OS.CGDataProviderRelease(provider); OS.CGContextScaleCTM (ctx, 1, -1); @@ -207,17 +207,17 @@ void drawWidget (int /*long*/ id, NSGraphicsContext context, NSRect rect) { drawRect.origin.y = caret.y; drawRect.size.width = caret.width != 0 ? caret.width : Caret.DEFAULT_WIDTH; drawRect.size.height = caret.height; - int /*long*/ colorspace = OS.CGColorSpaceCreateDeviceRGB(); + long /*int*/ colorspace = OS.CGColorSpaceCreateDeviceRGB(); OS.CGContextSetFillColorSpace(ctx, colorspace); OS.CGColorSpaceRelease(colorspace); - OS.CGContextSetFillColor(ctx, new float /*double*/ [] {1, 1, 1, 1}); + OS.CGContextSetFillColor(ctx, new double /*float*/ [] {1, 1, 1, 1}); OS.CGContextFillRect(ctx, drawRect); } OS.CGContextRestoreGState(ctx); } } -NSRect firstRectForCharacterRange (int /*long*/ id, int /*long*/ sel, int /*long*/ range) { +NSRect firstRectForCharacterRange (long /*int*/ id, long /*int*/ sel, long /*int*/ range) { if (ime != null) return ime.firstRectForCharacterRange (id, sel, range); return super.firstRectForCharacterRange (id, sel, range); } @@ -262,7 +262,7 @@ public IME getIME () { return ime; } -boolean hasMarkedText (int /*long*/ id, int /*long*/ sel) { +boolean hasMarkedText (long /*int*/ id, long /*int*/ sel) { if (ime != null) return ime.hasMarkedText (id, sel); return super.hasMarkedText (id, sel); } @@ -271,30 +271,30 @@ boolean imeInComposition () { return ime != null && ime.isInlineEnabled () && ime.startOffset != -1; } -boolean insertText (int /*long*/ id, int /*long*/ sel, int /*long*/ string) { +boolean insertText (long /*int*/ id, long /*int*/ sel, long /*int*/ string) { if (ime != null) { if (!ime.insertText (id, sel, string)) return false; } return super.insertText (id, sel, string); } -boolean isOpaque (int /*long*/ id, int /*long*/ sel) { +boolean isOpaque (long /*int*/ id, long /*int*/ sel) { if (glcontext != null) return true; return super.isOpaque(id, sel); } -NSRange markedRange (int /*long*/ id, int /*long*/ sel) { +NSRange markedRange (long /*int*/ id, long /*int*/ sel) { if (ime != null) return ime.markedRange (id, sel); return super.markedRange (id, sel); } -boolean readSelectionFromPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ pasteboard) { +boolean readSelectionFromPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ pasteboard) { boolean result = false; NSPasteboard pboard = new NSPasteboard(pasteboard); NSArray availableTypes = pboard.types(); NSString type; - for (int /*long*/ i = 0; i < supportedPboardTypes.count(); i++) { + for (long /*int*/ i = 0; i < supportedPboardTypes.count(); i++) { if (result) break; type = new NSString(supportedPboardTypes.objectAtIndex(i)); if (availableTypes.containsObject(type)) { @@ -487,7 +487,7 @@ public void scroll (int destX, int destY, int x, int y, int width, int height, b if (isFocus) caret.setFocus (); } -NSRange selectedRange (int /*long*/ id, int /*long*/ sel) { +NSRange selectedRange (long /*int*/ id, long /*int*/ sel) { if (ime != null) return ime.selectedRange (id, sel); return super.selectedRange (id, sel); } @@ -569,19 +569,19 @@ public void setIME (IME ime) { this.ime = ime; } -boolean setMarkedText_selectedRange (int /*long*/ id, int /*long*/ sel, int /*long*/ string, int /*long*/ range) { +boolean setMarkedText_selectedRange (long /*int*/ id, long /*int*/ sel, long /*int*/ string, long /*int*/ range) { if (ime != null) { if (!ime.setMarkedText_selectedRange (id, sel, string, range)) return false; } return super.setMarkedText_selectedRange (id, sel, string, range); } -int /*long*/ validAttributesForMarkedText (int /*long*/ id, int /*long*/ sel) { +long /*int*/ validAttributesForMarkedText (long /*int*/ id, long /*int*/ sel) { if (ime != null) return ime.validAttributesForMarkedText (id, sel); return super.validAttributesForMarkedText(id, sel); } -int /*long*/ validRequestorForSendType(int /*long*/ id, int /*long*/ sel, int /*long*/ sendType, int /*long*/ returnType) { +long /*int*/ validRequestorForSendType(long /*int*/ id, long /*int*/ sel, long /*int*/ sendType, long /*int*/ returnType) { if (id == view.id) { Accessible acc = getAccessible(); if (acc != null) { @@ -607,11 +607,11 @@ int /*long*/ validRequestorForSendType(int /*long*/ id, int /*long*/ sel, int /* return super.validRequestorForSendType(id, sel, sendType, returnType); } -void updateOpenGLContext(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void updateOpenGLContext(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { if (glcontext != null) ((NSOpenGLContext)glcontext).update(); } -void viewWillMoveToWindow(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void viewWillMoveToWindow(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { super.viewWillMoveToWindow(id, sel, arg0); if (glcontext != null && id == view.id && arg0 != 0) { Widget newShell = display.getWidget(new NSWindow(arg0).contentView()); @@ -625,21 +625,21 @@ void viewWillMoveToWindow(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) } } -boolean writeSelectionToPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ pasteboardObj, int /*long*/ typesObj) { +boolean writeSelectionToPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ pasteboardObj, long /*int*/ typesObj) { boolean result = false; NSPasteboard pboard = new NSPasteboard(pasteboardObj); NSArray types = new NSArray(typesObj); NSMutableArray typesToDeclare = NSMutableArray.arrayWithCapacity(2); NSString type; - for (int /*long*/ i = 0; i < supportedPboardTypes.count(); i++) { + for (long /*int*/ i = 0; i < supportedPboardTypes.count(); i++) { type = new NSString(supportedPboardTypes.objectAtIndex(i)); if (types.containsObject(type)) typesToDeclare.addObject(type); } if (typesToDeclare.count() > 0) { pboard.declareTypes(typesToDeclare, view); - for (int /*long*/ i = 0; i < typesToDeclare.count(); i++) { + for (long /*int*/ i = 0; i < typesToDeclare.count(); i++) { type = new NSString(typesToDeclare.objectAtIndex(i)); if (writeSelectionToPasteboard(pboard, type)) result = true; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ColorDialog.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ColorDialog.java index 7482cecba3..d67506821d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ColorDialog.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ColorDialog.java @@ -91,7 +91,7 @@ public ColorDialog(Shell parent, int style) { checkSubclass (); } -void changeColor(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void changeColor(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { selected = true; } @@ -167,7 +167,7 @@ public RGB open() { } } SWTPanelDelegate delegate = (SWTPanelDelegate)new SWTPanelDelegate().alloc().init(); - int /*long*/ jniRef = OS.NewGlobalRef(this); + long /*int*/ jniRef = OS.NewGlobalRef(this); if (jniRef == 0) error(SWT.ERROR_NO_HANDLES); OS.object_setInstanceVariable(delegate.id, Display.SWT_OBJECT, jniRef); panel.setDelegate(delegate); @@ -183,7 +183,7 @@ public RGB open() { if (selected) { NSColor color = panel.color(); if (color != null) { - float /*double*/ [] handle = display.getNSColorRGB(color); + double /*float*/ [] handle = display.getNSColorRGB(color); rgb = new RGB((int)(handle[0] * 255), (int)(handle[1] * 255), (int)(handle[2] * 255)); } } @@ -192,7 +192,7 @@ public RGB open() { rgbs = new RGB[length]; for (int i=0; i<length; i++) { NSString key = new NSString(keys.objectAtIndex(i)); - float /*double*/ [] handle = display.getNSColorRGB(colorList.colorWithKey(key)); + double /*float*/ [] handle = display.getNSColorRGB(colorList.colorWithKey(key)); rgbs[i] = new RGB((int)(handle[0] * 255), (int)(handle[1] * 255), (int)(handle[2] * 255)); } colorList.release(); @@ -228,7 +228,7 @@ public void setRGBs(RGB[] rgbs) { this.rgbs = rgbs; } -void windowWillClose(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void windowWillClose(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { NSApplication.sharedApplication().stop(null); } } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Combo.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Combo.java index 3d0edac256..fb7606e78d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Combo.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Combo.java @@ -136,7 +136,7 @@ public void add (String string) { NSAttributedString str = createString(string); if ((style & SWT.READ_ONLY) != 0) { NSPopUpButton widget = (NSPopUpButton)view; - int /*long*/ selection = widget.indexOfSelectedItem(); + long /*int*/ selection = widget.indexOfSelectedItem(); NSMenu nsMenu = widget.menu(); NSMenuItem nsItem = (NSMenuItem)new NSMenuItem().alloc(); NSString empty = NSString.string(); @@ -181,7 +181,7 @@ public void add (String string, int index) { NSAttributedString str = createString(string); if ((style & SWT.READ_ONLY) != 0) { NSPopUpButton widget = (NSPopUpButton)view; - int /*long*/ selection = widget.indexOfSelectedItem(); + long /*int*/ selection = widget.indexOfSelectedItem(); NSMenu nsMenu = widget.menu(); NSMenuItem nsItem = (NSMenuItem)new NSMenuItem().alloc(); NSString empty = NSString.string(); @@ -281,7 +281,7 @@ public void addVerifyListener (VerifyListener listener) { addListener (SWT.Verify, typedListener); } -boolean becomeFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean becomeFirstResponder (long /*int*/ id, long /*int*/ sel) { receivingFocus = true; boolean result = super.becomeFirstResponder (id, sel); receivingFocus = false; @@ -346,13 +346,13 @@ public void clearSelection () { } } -void setObjectValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void setObjectValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { super.setObjectValue(id, sel, ignoreSetObject ? arg0 : createString(text).id); } -void comboBoxSelectionDidChange(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void comboBoxSelectionDidChange(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { NSComboBox widget = (NSComboBox)view; - int /*long*/ tableSelection = widget.indexOfSelectedItem(); + long /*int*/ tableSelection = widget.indexOfSelectedItem(); widget.selectItemAtIndex(tableSelection); NSAttributedString attStr = new NSAttributedString (widget.itemObjectValueAtIndex(tableSelection)); NSString nsString = attStr.string(); @@ -456,12 +456,12 @@ void createWidget() { } } -void comboBoxWillDismiss(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void comboBoxWillDismiss(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { display.comboPoppedUp = false; listVisible = false; } -void comboBoxWillPopUp(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void comboBoxWillPopUp(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { display.comboPoppedUp = true; listVisible = true; } @@ -568,7 +568,7 @@ public void deselectAll () { sendEvent (SWT.Modify); } else { NSComboBox widget = (NSComboBox)view; - int /*long*/ index = widget.indexOfSelectedItem(); + long /*int*/ index = widget.indexOfSelectedItem(); if (index != -1) widget.deselectItemAtIndex(index); } } @@ -583,7 +583,7 @@ boolean dragDetect(int x, int y, boolean filter, boolean[] consume) { NSPoint textViewMouse = new NSPoint(); textViewMouse.x = x; textViewMouse.y = y; - int /*long*/ charPosition = feAsTextView.characterIndexForInsertionAtPoint(textViewMouse); + long /*int*/ charPosition = feAsTextView.characterIndexForInsertionAtPoint(textViewMouse); if (charPosition != OS.NSNotFound && charPosition >= selectedRange.location && charPosition < (selectedRange.location + selectedRange.length)) { if (super.dragDetect(x, y, filter, consume)) { if (consume != null) consume[0] = true; @@ -646,8 +646,8 @@ public Point getCaretLocation() { NSLayoutManager layoutManager = widget.layoutManager(); NSTextContainer container = widget.textContainer(); NSRange range = widget.selectedRange(); - int /*long*/ [] rectCount = new int /*long*/ [1]; - int /*long*/ pArray = layoutManager.rectArrayForCharacterRange(range, range, container, rectCount); + long /*int*/ [] rectCount = new long /*int*/ [1]; + long /*int*/ pArray = layoutManager.rectArrayForCharacterRange(range, range, container, rectCount); NSRect rect = new NSRect(); if (rectCount[0] > 0) OS.memmove(rect, pArray, NSRect.sizeof); NSPoint pt = new NSPoint(); @@ -888,7 +888,7 @@ char [] getText (int start, int end) { NSRange range = new NSRange (); range.location = start; if (end == -1) { - int /*long*/ length = str.length(); + long /*int*/ length = str.length(); range.length = length - start; } else { range.length = end - start; @@ -1018,19 +1018,19 @@ public int indexOf (String string, int start) { return -1; } -boolean isEventView (int /*long*/ id) { +boolean isEventView (long /*int*/ id) { return true; } -void menuWillOpen(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuWillOpen(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { listVisible = true; } -void menuDidClose(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuDidClose(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { listVisible = false; } -void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { // If this is a combo box with an editor field and the control is disposed // while the view's cell editor is open we crash while tearing down the // popup window. Fix is to retain the view before letting Cocoa track @@ -1311,7 +1311,7 @@ boolean sendKeyEvent (NSEvent nsEvent, int type) { boolean result = super.sendKeyEvent (nsEvent, type); if (!result) return result; int stateMask = 0; - int /*long*/ modifierFlags = nsEvent.modifierFlags(); + long /*int*/ modifierFlags = nsEvent.modifierFlags(); if ((modifierFlags & OS.NSAlternateKeyMask) != 0) stateMask |= SWT.ALT; if ((modifierFlags & OS.NSShiftKeyMask) != 0) stateMask |= SWT.SHIFT; if ((modifierFlags & OS.NSControlKeyMask) != 0) stateMask |= SWT.CONTROL; @@ -1377,7 +1377,7 @@ void setFont (NSFont font) { updateItems(); } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { super.setForeground(color); updateItems(); if ((style & SWT.READ_ONLY) == 0) { @@ -1664,14 +1664,14 @@ public void setVisibleItemCount (int count) { } } -boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ sel, int /*long*/ affectedCharRange, int /*long*/ replacementString) { +boolean shouldChangeTextInRange_replacementString(long /*int*/ id, long /*int*/ sel, long /*int*/ affectedCharRange, long /*int*/ replacementString) { NSRange range = new NSRange(); OS.memmove(range, affectedCharRange, NSRange.sizeof); boolean result = callSuperBoolean(id, sel, range, replacementString); if (hooks (SWT.Verify)) { String string = new NSString(replacementString).getString(); NSEvent currentEvent = display.application.currentEvent(); - int /*long*/ type = currentEvent.type(); + long /*int*/ type = currentEvent.type(); if (type != OS.NSKeyDown && type != OS.NSKeyUp) currentEvent = null; String newText = verifyText(string, (int)/*64*/range.location, (int)/*64*/(range.location+range.length), currentEvent); if (newText == null) return false; @@ -1705,18 +1705,18 @@ boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ return result; } -void textViewDidChangeSelection(int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textViewDidChangeSelection(long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { NSNotification notification = new NSNotification(aNotification); NSText editor = new NSText(notification.object().id); selectionRange = editor.selectedRange(); } -void textDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textDidChange (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { super.textDidChange (id, sel, aNotification); postEvent (SWT.Modify); } -NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange(int /*long*/ id, int /*long*/ sel, int /*long*/ aTextView, int /*long*/ oldSelectedCharRange, int /*long*/ newSelectedCharRange) { +NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange(long /*int*/ id, long /*int*/ sel, long /*int*/ aTextView, long /*int*/ oldSelectedCharRange, long /*int*/ newSelectedCharRange) { /* * If the selection is changing as a result of the receiver getting focus * then return the receiver's last selection range, otherwise the full diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java index e2622c6878..f9c3e8e9a0 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java @@ -127,14 +127,14 @@ Control [] _getTabList () { return tabList; } -boolean acceptsFirstMouse (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +boolean acceptsFirstMouse (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if ((state & CANVAS) != 0) { return true; } return super.acceptsFirstMouse (id, sel, theEvent); } -boolean acceptsFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean acceptsFirstResponder (long /*int*/ id, long /*int*/ sel) { if ((state & CANVAS) != 0) { if ((style & SWT.NO_FOCUS) == 0 && hooksKeys ()) { if (contentView().subviews().count() == 0) return true; @@ -144,9 +144,9 @@ boolean acceptsFirstResponder (int /*long*/ id, int /*long*/ sel) { return super.acceptsFirstResponder (id, sel); } -int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityAttributeValue (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { NSString nsAttributeName = new NSString(arg0); - int /*long*/ superValue = super.accessibilityAttributeValue(id, sel, arg0); + long /*int*/ superValue = super.accessibilityAttributeValue(id, sel, arg0); if ((state & CANVAS) != 0) { // If this Composite has an Accessible that defined a role, return that, unless the @@ -177,7 +177,7 @@ int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { if (id == accessibleHandle()) { // If a Composite or subclass has an Accessible it should not be ignored. if (accessible != null) return accessible.internal_accessibilityIsIgnored(ACC.CHILDID_SELF); @@ -357,7 +357,7 @@ public void drawBackground(GC gc, int x, int y, int width, int height, int offse } } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; if ((state & CANVAS) != 0) { if ((style & SWT.NO_BACKGROUND) == 0) { @@ -570,7 +570,7 @@ public boolean isLayoutDeferred () { return findDeferredControl () != null; } -boolean isOpaque (int /*long*/ id, int /*long*/ sel) { +boolean isOpaque (long /*int*/ id, long /*int*/ sel) { if ((state & CANVAS) != 0) { if (id == view.id) { return region == null && background != null && background[3] == 1 && !isObscured (); @@ -584,7 +584,7 @@ boolean isTabGroup () { return super.isTabGroup (); } -void keyDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyDown (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (hasFocus()) { if ((state & CANVAS) != 0) { Shell s = this.getShell(); @@ -882,22 +882,22 @@ Point minimumSize (int wHint, int Hint, boolean changed) { return new Point (width, height); } -boolean mouseEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent, int type) { +boolean mouseEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent, int type) { boolean result = super.mouseEvent (id, sel, theEvent, type); return (state & CANVAS) == 0 ? result : new NSEvent (theEvent).type () != OS.NSLeftMouseDown; } -void pageDown(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void pageDown(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { if ((state & CANVAS) != 0) return; super.pageDown(id, sel, sender); } -void pageUp(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void pageUp(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { if ((state & CANVAS) != 0) return; super.pageUp(id, sel, sender); } -void reflectScrolledClipView (int /*long*/ id, int /*long*/ sel, int /*long*/ aClipView) { +void reflectScrolledClipView (long /*int*/ id, long /*int*/ sel, long /*int*/ aClipView) { if ((state & CANVAS) != 0) return; super.reflectScrolledClipView (id, sel, aClipView); } @@ -941,15 +941,15 @@ void resized () { } } -void scrollWheel (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void scrollWheel (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if ((state & CANVAS) != 0) { NSView view = scrollView != null ? scrollView : this.view; if (id == view.id) { getShell().deferFlushing(); NSEvent nsEvent = new NSEvent(theEvent); boolean handled = false; - float /*double*/ deltaY = nsEvent.deltaY(); - float /*double*/ deltaX = nsEvent.deltaX (); + double /*float*/ deltaY = nsEvent.deltaY(); + double /*float*/ deltaX = nsEvent.deltaX (); if ((hooks(SWT.Gesture) || filters (SWT.Gesture))) { if (deltaX != 0 || deltaY != 0) { if (!gestureEvent(id, theEvent, SWT.GESTURE_PAN)) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java index c5f471ed11..dded880d88 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java @@ -60,13 +60,13 @@ public abstract class Control extends Widget implements Drawable { Object layoutData; int drawCount; Menu menu; - float /*double*/ [] foreground, background; + double /*float*/ [] foreground, background; Image backgroundImage; Font font; Cursor cursor; Region region; NSBezierPath regionPath; - int /*long*/ visibleRgn; + long /*int*/ visibleRgn; Accessible accessible; boolean touchEnabled; @@ -118,14 +118,14 @@ public Control (Composite parent, int style) { createWidget (); } -boolean acceptsFirstMouse (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +boolean acceptsFirstMouse (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { Shell shell = getShell (); if ((shell.style & SWT.ON_TOP) != 0) return true; return super.acceptsFirstMouse (id, sel, theEvent); } -int /*long*/ accessibleHandle() { - int /*long*/ returnValue = view.id; +long /*int*/ accessibleHandle() { + long /*int*/ returnValue = view.id; if (view instanceof NSControl) { if (((NSControl) view).cell() != null) { @@ -136,7 +136,7 @@ int /*long*/ accessibleHandle() { return returnValue; } -int /*long*/ accessibilityActionDescription(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityActionDescription(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { if (id == accessibleHandle() && accessible != null) { NSString actionName = new NSString(arg0); id returnValue = accessible.internal_accessibilityActionDescription(actionName, ACC.CHILDID_SELF); @@ -145,8 +145,8 @@ int /*long*/ accessibilityActionDescription(int /*long*/ id, int /*long*/ sel, i return super.accessibilityActionDescription(id, sel, arg0); } -int /*long*/ accessibilityActionNames(int /*long*/ id, int /*long*/ sel) { - int /*long*/ returnValue = super.accessibilityActionNames(id, sel); +long /*int*/ accessibilityActionNames(long /*int*/ id, long /*int*/ sel) { + long /*int*/ returnValue = super.accessibilityActionNames(id, sel); if (handleIsAccessible(id)) { if (accessible != null) { NSArray baseArray = accessible.internal_accessibilityActionNames(ACC.CHILDID_SELF); @@ -163,9 +163,9 @@ int /*long*/ accessibilityActionNames(int /*long*/ id, int /*long*/ sel) { return returnValue; } -int /*long*/ accessibilityAttributeNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityAttributeNames(long /*int*/ id, long /*int*/ sel) { - int /*long*/ returnValue = 0; + long /*int*/ returnValue = 0; if (handleIsAccessible(id) && accessible != null) { // See if the accessible is defining the attribute set for the control. @@ -191,11 +191,11 @@ int /*long*/ accessibilityAttributeNames(int /*long*/ id, int /*long*/ sel) { * or overridden by the SWT Accessible. false if the Cocoa defaults for the control should * be used. */ -boolean handleIsAccessible(int /*long*/ id) { +boolean handleIsAccessible(long /*int*/ id) { return id == accessibleHandle(); } -int /*long*/ accessibilityParameterizedAttributeNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityParameterizedAttributeNames(long /*int*/ id, long /*int*/ sel) { if (handleIsAccessible(id) && accessible != null) { NSArray returnValue = accessible.internal_accessibilityParameterizedAttributeNames(ACC.CHILDID_SELF); @@ -205,7 +205,7 @@ int /*long*/ accessibilityParameterizedAttributeNames(int /*long*/ id, int /*lon return super.accessibilityParameterizedAttributeNames(id, sel); } -void accessibilityPerformAction(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void accessibilityPerformAction(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { if (handleIsAccessible(id) && accessible != null) { NSString action = new NSString(arg0); if (accessible.internal_accessibilityPerformAction(action, ACC.CHILDID_SELF)) return; @@ -213,7 +213,7 @@ void accessibilityPerformAction(int /*long*/ id, int /*long*/ sel, int /*long*/ super.accessibilityPerformAction(id, sel, arg0); } -int /*long*/ accessibilityFocusedUIElement(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityFocusedUIElement(long /*int*/ id, long /*int*/ sel) { id returnValue = null; if (handleIsAccessible(id) && accessible != null) { @@ -228,7 +228,7 @@ int /*long*/ accessibilityFocusedUIElement(int /*long*/ id, int /*long*/ sel) { return returnValue.id; } -int /*long*/ accessibilityHitTest(int /*long*/ id, int /*long*/ sel, NSPoint point) { +long /*int*/ accessibilityHitTest(long /*int*/ id, long /*int*/ sel, NSPoint point) { id returnValue = null; if (handleIsAccessible(id) && accessible != null) { @@ -243,9 +243,9 @@ int /*long*/ accessibilityHitTest(int /*long*/ id, int /*long*/ sel, NSPoint poi return returnValue.id; } -int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityAttributeValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { NSString attribute = new NSString(arg0); - int /*long*/ returnValue = 0; + long /*int*/ returnValue = 0; id returnObject = null; if (handleIsAccessible(id) && accessible != null) { @@ -272,7 +272,7 @@ int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int return returnValue; } -int /*long*/ accessibilityAttributeValue_forParameter(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +long /*int*/ accessibilityAttributeValue_forParameter(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { NSString attribute = new NSString(arg0); id returnValue = null; @@ -290,7 +290,7 @@ int /*long*/ accessibilityAttributeValue_forParameter(int /*long*/ id, int /*lon return returnValue.id; } -boolean accessibilityIsAttributeSettable(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +boolean accessibilityIsAttributeSettable(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { boolean returnValue = false; if (handleIsAccessible(id) && accessible != null) { NSString attribute = new NSString (arg0); @@ -302,7 +302,7 @@ boolean accessibilityIsAttributeSettable(int /*long*/ id, int /*long*/ sel, int return returnValue; } -void accessibilitySetValue_forAttribute(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +void accessibilitySetValue_forAttribute(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { if (handleIsAccessible(id) && accessible != null) { id value = new id(arg0); NSString attribute = new NSString(arg1); @@ -732,25 +732,25 @@ public void addTraverseListener (TraverseListener listener) { addListener (SWT.Traverse,typedListener); } -boolean becomeFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean becomeFirstResponder (long /*int*/ id, long /*int*/ sel) { if ((state & DISABLED) != 0) return false; return super.becomeFirstResponder (id, sel); } -void beginGestureWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void beginGestureWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!gestureEvent(id, event, SWT.GESTURE_BEGIN)) return; super.beginGestureWithEvent(id, sel, event); } -void endGestureWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void endGestureWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!gestureEvent(id, event, SWT.GESTURE_END)) return; super.endGestureWithEvent(id, sel, event); } -void calculateVisibleRegion (NSView view, int /*long*/ visibleRgn, boolean clipChildren) { - int /*long*/ tempRgn = OS.NewRgn (); +void calculateVisibleRegion (NSView view, long /*int*/ visibleRgn, boolean clipChildren) { + long /*int*/ tempRgn = OS.NewRgn (); if (!view.isHiddenOrHasHiddenAncestor() && isDrawing()) { - int /*long*/ childRgn = OS.NewRgn (); + long /*int*/ childRgn = OS.NewRgn (); NSWindow window = view.window (); NSView contentView = window.contentView(); NSView frameView = contentView.superview(); @@ -769,7 +769,7 @@ void calculateVisibleRegion (NSView view, int /*long*/ visibleRgn, boolean clipC if (OS.EmptyRgn (visibleRgn)) break; if (clipChildren || tempView.id != view.id) { NSArray subviews = tempView.subviews(); - int /*long*/ count = subviews.count(); + long /*int*/ count = subviews.count(); for (int i = 0; i < count; i++) { NSView child = new NSView (subviews.objectAtIndex(count - i - 1)); if (lastControl != null && child.id == lastControl.id) break; @@ -792,7 +792,7 @@ void calculateVisibleRegion (NSView view, int /*long*/ visibleRgn, boolean clipC OS.DisposeRgn (tempRgn); } -void cancelOperation(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void cancelOperation(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { // Cmd-. and escape arrive here. Forward the current event as a key event. if (hasKeyboardFocus(id)) { NSEvent nsEvent = NSApplication.sharedApplication().currentEvent(); @@ -952,7 +952,7 @@ NSView contentView () { return view; } -NSAttributedString createString (String string, Font font, float /*double*/ [] foreground, int alignment, boolean wrap, boolean enabled, boolean mnemonics) { +NSAttributedString createString (String string, Font font, double /*float*/ [] foreground, int alignment, boolean wrap, boolean enabled, boolean mnemonics) { NSMutableDictionary dict = ((NSMutableDictionary)new NSMutableDictionary().alloc()).initWithCapacity(5); if (font == null) font = this.font != null ? this.font : defaultFont(); dict.setObject (font.handle, OS.NSFontAttributeName); @@ -1037,7 +1037,7 @@ void destroyWidget () { releaseHandle (); } -void doCommandBySelector (int /*long*/ id, int /*long*/ sel, int /*long*/ selector) { +void doCommandBySelector (long /*int*/ id, long /*int*/ sel, long /*int*/ selector) { if (hasKeyboardFocus(id)) { if (imeInComposition ()) return; Shell s = this.getShell(); @@ -1051,7 +1051,7 @@ void doCommandBySelector (int /*long*/ id, int /*long*/ sel, int /*long*/ select * during this keystroke. This rule does not apply if the command key * is down, because we likely triggered the current key sequence via flagsChanged. */ - int /*long*/ modifiers = nsEvent.modifierFlags(); + long /*int*/ modifiers = nsEvent.modifierFlags(); if (s.keyInputHappened == false || (modifiers & OS.NSCommandKeyMask) != 0) { s.keyInputHappened = true; boolean [] consume = new boolean [1]; @@ -1165,9 +1165,9 @@ boolean dragDetect (int x, int y, boolean filter, boolean [] consume) { */ NSApplication application = NSApplication.sharedApplication(); boolean dragging = false; - int /*long*/ eventType = OS.NSLeftMouseDown; - float /*double*/ dragX = x; - float /*double*/ dragY = y; + long /*int*/ eventType = OS.NSLeftMouseDown; + double /*float*/ dragX = x; + double /*float*/ dragY = y; /** * To check for an actual drag we need to pull off mouse moved and mouse up events @@ -1227,7 +1227,7 @@ boolean drawsBackground() { return true; } -void drawWidget (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawWidget (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != paintView().id) return; if (!hooks (SWT.Paint) && !filters (SWT.Paint)) return; @@ -1253,7 +1253,7 @@ void enableWidget (boolean enabled) { updateCursorRects (isEnabled ()); } -boolean equals(float /*double*/ [] color1, float /*double*/ [] color2) { +boolean equals(double /*float*/ [] color1, double /*float*/ [] color2) { if (color1 == color2) return true; if (color1 == null) return color2 == null; if (color2 == null) return color1 == null; @@ -1305,8 +1305,8 @@ void fillBackground (NSView view, NSGraphicsContext context, NSRect rect, int im return; } - float /*double*/ [] background = control.background; - float /*double*/ alpha; + double /*float*/ [] background = control.background; + double /*float*/ alpha; if (background == null) { if (isTransparent()) return; background = control.defaultBackground ().handle; @@ -1358,14 +1358,14 @@ void fixFocus (Control focusControl) { } } -void flagsChanged (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void flagsChanged (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (hasKeyboardFocus(id)) { if ((state & WEBKIT_EVENTS_FIX) == 0) { Shell s = this.getShell(); s.keyInputHappened = false; int mask = 0; NSEvent nsEvent = new NSEvent (theEvent); - int /*long*/ modifiers = nsEvent.modifierFlags (); + long /*int*/ modifiers = nsEvent.modifierFlags (); int keyCode = Display.translateKey (nsEvent.keyCode ()); switch (keyCode) { case SWT.ALT: mask = OS.NSAlternateKeyMask; break; @@ -1445,7 +1445,7 @@ boolean forceFocus (NSView focusView) { return window.makeFirstResponder (focusView); } -boolean gestureEvent(int /*long*/ id, int /*long*/ eventPtr, int detail) { +boolean gestureEvent(long /*int*/ id, long /*int*/ eventPtr, int detail) { if (!display.sendEvent) return true; display.sendEvent = false; // For cross-platform compatibility, touch events and gestures are mutually exclusive. @@ -1864,7 +1864,7 @@ NSBezierPath getPath(Region region) { return getPath(region.handle); } -NSBezierPath getPath(int /*long*/ region) { +NSBezierPath getPath(long /*int*/ region) { Callback callback = new Callback(this, "regionToRects", 4); if (callback.getAddress() == 0) error(SWT.ERROR_NO_MORE_CALLBACKS); NSBezierPath path = NSBezierPath.bezierPath(); @@ -1999,12 +1999,12 @@ public boolean getVisible () { return (state & HIDDEN) == 0; } -int /*long*/ getVisibleRegion () { +long /*int*/ getVisibleRegion () { if (visibleRgn == 0) { visibleRgn = OS.NewRgn (); calculateVisibleRegion (view, visibleRgn, true); } - int /*long*/ result = OS.NewRgn (); + long /*int*/ result = OS.NewRgn (); OS.CopyRgn (visibleRgn, result); return result; } @@ -2021,7 +2021,7 @@ boolean hasRegion () { return region != null || parent.hasRegion (); } -int /*long*/ hitTest (int /*long*/ id, int /*long*/ sel, NSPoint point) { +long /*int*/ hitTest (long /*int*/ id, long /*int*/ sel, NSPoint point) { if ((state & DISABLED) != 0) return 0; if (!isActive ()) return 0; if (regionPath != null) { @@ -2037,7 +2037,7 @@ boolean imeInComposition () { return false; } -boolean insertText (int /*long*/ id, int /*long*/ sel, int /*long*/ string) { +boolean insertText (long /*int*/ id, long /*int*/ sel, long /*int*/ string) { // sendKeyEvent may do something to run the event loop. That would cause // 'string' to be released before any superclass could use it, so save it // until this method finishes. @@ -2048,7 +2048,7 @@ boolean insertText (int /*long*/ id, int /*long*/ sel, int /*long*/ string) { Shell s = this.getShell(); NSEvent nsEvent = NSApplication.sharedApplication ().currentEvent (); if (nsEvent != null) { - int /*long*/ type = nsEvent.type (); + long /*int*/ type = nsEvent.type (); if (type == OS.NSKeyDown || type == OS.NSSystemDefined) { NSString str = new NSString (string); if (str.isKindOfClass (OS.class_NSAttributedString)) { @@ -2090,10 +2090,10 @@ boolean insertText (int /*long*/ id, int /*long*/ sel, int /*long*/ string) { * * @noreference This method is not intended to be referenced by clients. */ -public int /*long*/ internal_new_GC (GCData data) { +public long /*int*/ internal_new_GC (GCData data) { checkWidget(); NSView view = paintView(); - int /*long*/ context = 0; + long /*int*/ context = 0; if (data != null && data.paintRect != null) { NSGraphicsContext graphicsContext = NSGraphicsContext.currentContext(); context = graphicsContext.id; @@ -2105,7 +2105,7 @@ public int /*long*/ internal_new_GC (GCData data) { * to create a GC on a deferred NSWindow. */ if (window.windowNumber() <= 0) { - float /*double*/ alpha = window.alphaValue(); + double /*float*/ alpha = window.alphaValue(); window.setAlphaValue(0); window.orderBack(null); window.orderOut(null); @@ -2156,9 +2156,9 @@ public int /*long*/ internal_new_GC (GCData data) { * * @noreference This method is not intended to be referenced by clients. */ -public void internal_dispose_GC (int /*long*/ hDC, GCData data) { +public void internal_dispose_GC (long /*int*/ hDC, GCData data) { checkWidget (); - int /*long*/ context = hDC; + long /*int*/ context = hDC; NSGraphicsContext graphicsContext = new NSGraphicsContext (context); display.removeContext (data); if (data != null) { @@ -2257,7 +2257,7 @@ public boolean isFocusControl () { } boolean isObscured () { - int /*long*/ visibleRgn = getVisibleRegion(), boundsRgn = OS.NewRgn(); + long /*int*/ visibleRgn = getVisibleRegion(), boundsRgn = OS.NewRgn(); short[] rect = new short[4]; NSRect bounds = view.visibleRect(); OS.SetRect(rect, (short)bounds.x, (short)bounds.y, (short)(bounds.x + bounds.width), (short)(bounds.y + bounds.height)); @@ -2357,7 +2357,7 @@ public boolean isVisible () { return getVisible () && parent.isVisible (); } -void keyDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyDown (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (hasKeyboardFocus(id)) { Shell s = this.getShell(); s.keyInputHappened = false; @@ -2391,11 +2391,11 @@ void keyDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { super.keyDown (id, sel, theEvent); } -boolean hasKeyboardFocus(int /*long*/ inId) { +boolean hasKeyboardFocus(long /*int*/ inId) { return view.window().firstResponder().id == inId; } -void keyUp (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyUp (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (hasKeyboardFocus(id)) { NSEvent nsEvent = new NSEvent (theEvent); if (!sendKeyEvent (nsEvent, SWT.KeyUp)) return; @@ -2403,7 +2403,7 @@ void keyUp (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { super.keyUp (id, sel, theEvent); } -void magnifyWithEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void magnifyWithEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!gestureEvent(id, event, SWT.GESTURE_MAGNIFY)) return; super.magnifyWithEvent(id, sel, event); } @@ -2412,7 +2412,7 @@ void markLayout (boolean changed, boolean all) { /* Do nothing */ } -int /*long*/ menuForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +long /*int*/ menuForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!isEnabled ()) return 0; NSPoint pt = NSEvent.mouseLocation(); @@ -2443,7 +2443,7 @@ Decorations menuShell () { return parent.menuShell (); } -void scrollWheel (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void scrollWheel (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { boolean handled = false; if (id == view.id) { NSEvent nsEvent = new NSEvent(theEvent); @@ -2474,11 +2474,11 @@ void scrollWheel (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { if (!handled) super.scrollWheel(id, sel, theEvent); } -boolean isEventView (int /*long*/ id) { +boolean isEventView (long /*int*/ id) { return true; } -boolean mouseEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent, int type) { +boolean mouseEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent, int type) { if (!display.sendEvent) return true; display.sendEvent = false; if (!isEventView (id)) return true; @@ -2530,7 +2530,7 @@ boolean mouseEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent, in return true; } -void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseDown)) return; boolean tracking = isEventView (id); Display display = this.display; @@ -2539,42 +2539,42 @@ void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { if (tracking) display.trackingControl = null; } -void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseUp)) return; super.mouseUp(id, sel, theEvent); } -void mouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseMove)) return; super.mouseDragged(id, sel, theEvent); } -void rightMouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseDown)) return; super.rightMouseDown(id, sel, theEvent); } -void rightMouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseUp)) return; super.rightMouseUp(id, sel, theEvent); } -void rightMouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseMove)) return; super.rightMouseDragged(id, sel, theEvent); } -void otherMouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseDown)) return; super.otherMouseDown(id, sel, theEvent); } -void otherMouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseUp)) return; super.otherMouseUp(id, sel, theEvent); } -void otherMouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!mouseEvent(id, sel, theEvent, SWT.MouseMove)) return; super.otherMouseDragged(id, sel, theEvent); } @@ -2794,7 +2794,7 @@ public void redraw (int x, int y, int width, int height, boolean all) { view.setNeedsDisplayInRect(rect); } -int /*long*/ regionToRects(int /*long*/ message, int /*long*/ rgn, int /*long*/ r, int /*long*/ path) { +long /*int*/ regionToRects(long /*int*/ message, long /*int*/ rgn, long /*int*/ r, long /*int*/ path) { NSPoint pt = new NSPoint(); short[] rect = new short[4]; if (message == OS.kQDRegionToRectsMsgParse) { @@ -3252,7 +3252,7 @@ void resetVisibleRegion () { } GCData[] gcs = display.contexts; if (gcs != null) { - int /*long*/ visibleRgn = 0; + long /*int*/ visibleRgn = 0; for (int i=0; i<gcs.length; i++) { GCData data = gcs [i]; if (data != null) { @@ -3271,7 +3271,7 @@ void resized () { sendEvent (SWT.Resize); } -void rotateWithEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void rotateWithEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!gestureEvent(id, event, SWT.GESTURE_ROTATE)) return; super.rotateWithEvent(id, sel, event); } @@ -3338,12 +3338,12 @@ boolean sendMouseEvent (NSEvent nsEvent, int type, boolean send) { break; case SWT.MouseWheel: { event.detail = SWT.SCROLL_LINE; - float /*double*/ delta = nsEvent.deltaY(); + double /*float*/ delta = nsEvent.deltaY(); event.count = delta > 0 ? Math.max (1, (int)delta) : Math.min (-1, (int)delta); break; } case SWT.MouseHorizontalWheel: { - float /*double*/ delta = nsEvent.deltaX(); + double /*float*/ delta = nsEvent.deltaX(); event.count = delta > 0 ? Math.max (1, (int)delta) : Math.min (-1, (int)delta); break; } @@ -3376,7 +3376,7 @@ boolean sendMouseEvent (NSEvent nsEvent, int type, boolean send) { Touch touchStateFromNSTouch(NSTouch touch) { TouchSource source = display.findTouchSource(touch); - int /*long*/ osPhase = touch.phase(); + long /*int*/ osPhase = touch.phase(); long identity = OS.objc_msgSend(touch.id, OS.sel_identity); int state = 0; @@ -3408,8 +3408,8 @@ Touch touchStateFromNSTouch(NSTouch touch) { } NSTouch findTouchWithId(NSArray touches, NSObject identity) { - int /*long*/ count = touches.count(); - for (int /*long*/ i = 0; i < count; i++) { + long /*int*/ count = touches.count(); + for (long /*int*/ i = 0; i < count; i++) { NSTouch aTouch = new NSTouch(touches.objectAtIndex(i).id); NSObject currIdentity = new NSObject(OS.objc_msgSend(aTouch.id, OS.sel_identity)); if (currIdentity.isEqual(identity)) return aTouch; @@ -3424,7 +3424,7 @@ void setBackground () { if (control.backgroundImage != null) { setBackgroundImage (control.backgroundImage.handle); } else { - float /*double*/ [] color = control.background != null ? control.background : control.defaultBackground().handle; + double /*float*/ [] color = control.background != null ? control.background : control.defaultBackground().handle; NSColor nsColor = NSColor.colorWithDeviceRed(color[0], color[1], color[2], color[3]); setBackgroundColor (nsColor); } @@ -3453,7 +3453,7 @@ public void setBackground (Color color) { if (color != null) { if (color.isDisposed()) error(SWT.ERROR_INVALID_ARGUMENT); } - float /*double*/ [] background = color != null ? color.handle : null; + double /*float*/ [] background = color != null ? color.handle : null; if (equals (background, this.background)) return; this.background = background; updateBackgroundColor (); @@ -3766,17 +3766,17 @@ public void setForeground (Color color) { if (color != null) { if (color.isDisposed()) error(SWT.ERROR_INVALID_ARGUMENT); } - float /*double*/ [] foreground = color != null ? color.handle : null; + double /*float*/ [] foreground = color != null ? color.handle : null; if (equals (foreground, this.foreground)) return; this.foreground = foreground; setForeground (foreground); redrawWidget (view, false); } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { } -void setFrameOrigin (int /*long*/ id, int /*long*/ sel, NSPoint point) { +void setFrameOrigin (long /*int*/ id, long /*int*/ sel, NSPoint point) { NSView topView = topView (); if (topView.id != id) { super.setFrameOrigin(id, sel, point); @@ -3790,7 +3790,7 @@ void setFrameOrigin (int /*long*/ id, int /*long*/ sel, NSPoint point) { } } -void setFrameSize (int /*long*/ id, int /*long*/ sel, NSSize size) { +void setFrameSize (long /*int*/ id, long /*int*/ sel, NSSize size) { NSView topView = topView (); if (topView.id != id) { super.setFrameSize(id, sel, size); @@ -4219,7 +4219,7 @@ void setZOrder () { parent.contentView().addSubview(topView, OS.NSWindowBelow, null); } -boolean shouldDelayWindowOrderingForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +boolean shouldDelayWindowOrderingForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { Shell shell = getShell (); if ((shell.style & SWT.ON_TOP) != 0) return false; return super.shouldDelayWindowOrderingForEvent (id, sel, theEvent); @@ -4312,7 +4312,7 @@ void sort (int [] items) { } } -void swipeWithEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void swipeWithEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!gestureEvent(id, event, SWT.GESTURE_SWIPE)) return; super.swipeWithEvent(id, sel, event); } @@ -4418,7 +4418,7 @@ NSView topView () { return view; } -boolean touchEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ eventPtr) { +boolean touchEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ eventPtr) { if (!display.sendEvent) return true; display.sendEvent = false; if (!(hooks(SWT.Touch) || filters(SWT.Touch))) return true; @@ -4435,7 +4435,7 @@ boolean touchEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ eventPtr) { event.y = (int) location.y; setInputState (event, nsEvent, SWT.Touch); NSSet allTouchesSet = nsEvent.touchesMatchingPhase(OS.NSTouchPhaseAny, null); - int /*long*/ touchCount = allTouchesSet.count(); + long /*int*/ touchCount = allTouchesSet.count(); Touch touches[] = new Touch[(int)/*64*/touchCount]; int currTouchIndex = 0; @@ -4469,7 +4469,7 @@ boolean touchEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ eventPtr) { * if a 4-finger gesture occurs and the application switcher appears. Workaround is to generate a TOUCHSTATE_UP for the * orphaned touch. */ - for (int /*long*/ j = currentTouches.count() - 1; j >= 0 ; j--) { + for (long /*int*/ j = currentTouches.count() - 1; j >= 0 ; j--) { NSTouch touch = new NSTouch(currentTouches.objectAtIndex(j).id); NSObject identity = new NSObject(OS.objc_msgSend(touch.id, OS.sel_identity)); NSTouch activeTouch = findTouchWithId(activeTouches, identity); @@ -4494,22 +4494,22 @@ boolean touchEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ eventPtr) { return true; } -void touchesBeganWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesBeganWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!touchEvent(id, sel, event)) return; super.touchesBeganWithEvent(id, sel, event); } -void touchesCancelledWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesCancelledWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!touchEvent(id, sel, event)) return; super.touchesCancelledWithEvent(id, sel, event); } -void touchesEndedWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesEndedWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!touchEvent(id, sel, event)) return; super.touchesEndedWithEvent(id, sel, event); } -void touchesMovedWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesMovedWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { if (!touchEvent(id, sel, event)) return; super.touchesMovedWithEvent(id, sel, event); } @@ -4531,7 +4531,7 @@ boolean translateTraversal (int key, NSEvent theEvent, boolean [] consume) { break; } case 48: /* Tab */ { - int /*long*/ modifiers = theEvent.modifierFlags (); + long /*int*/ modifiers = theEvent.modifierFlags (); boolean next = (modifiers & OS.NSShiftKeyMask) == 0; detail = next ? SWT.TRAVERSE_TAB_NEXT : SWT.TRAVERSE_TAB_PREVIOUS; break; @@ -4547,7 +4547,7 @@ boolean translateTraversal (int key, NSEvent theEvent, boolean [] consume) { case 116: /* Page up */ case 121: /* Page down */ { all = true; - int /*long*/ modifiers = theEvent.modifierFlags (); + long /*int*/ modifiers = theEvent.modifierFlags (); if ((modifiers & OS.NSControlKeyMask) == 0) return false; detail = key == 121 /* Page down */ ? SWT.TRAVERSE_PAGE_NEXT : SWT.TRAVERSE_PAGE_PREVIOUS; break; @@ -4913,7 +4913,7 @@ void update (boolean all) { void updateBackgroundColor () { Control control = findBackgroundControl (); if (control == null) control = this; - float /*double*/ [] color = control.background != null ? control.background : control.defaultBackground().handle; + double /*float*/ [] color = control.background != null ? control.background : control.defaultBackground().handle; NSColor nsColor = NSColor.colorWithDeviceRed(color[0], color[1], color[2], color[3]); setBackgroundColor (nsColor); } @@ -4932,11 +4932,11 @@ void updateBackgroundMode () { } } -void resetCursorRects (int /*long*/ id, int /*long*/ sel) { +void resetCursorRects (long /*int*/ id, long /*int*/ sel) { if (isEnabled ()) callSuper (id, sel); } -void updateTrackingAreas (int /*long*/ id, int /*long*/ sel) { +void updateTrackingAreas (long /*int*/ id, long /*int*/ sel) { if (isEnabled ()) callSuper (id, sel); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DateTime.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DateTime.java index 7f2801f906..61076d20d7 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DateTime.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DateTime.java @@ -279,7 +279,7 @@ void disposePopupShell() { popupCalendar = null; } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; fillBackground (view, context, rect, -1); } @@ -457,16 +457,16 @@ boolean isDropped () { return popupShell.getVisible (); } -boolean isEventView (int /*long*/ id) { +boolean isEventView (long /*int*/ id) { return true; } -boolean isFlipped (int /*long*/ id, int /*long*/ sel) { +boolean isFlipped (long /*int*/ id, long /*int*/ sel) { if ((style & SWT.CALENDAR) != 0) return super.isFlipped (id, sel); return true; } -void keyDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if ((style & SWT.DROP_DOWN) != 0) { NSEvent nsEvent = new NSEvent (theEvent); int keyCode = Display.translateKey (nsEvent.keyCode ()); @@ -651,7 +651,7 @@ public void setDay (int day) { } } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { NSColor nsColor; if (color == null) { if ((style & SWT.CALENDAR) != 0) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DirectoryDialog.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DirectoryDialog.java index edeaa3d34e..5a044d5ce3 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DirectoryDialog.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/DirectoryDialog.java @@ -138,7 +138,7 @@ public String open () { } display.setModalDialog(this); NSString dir = (filterPath != null && filterPath.length() > 0) ? NSString.stringWith(filterPath) : null; - int /*long*/ response = panel.runModalForDirectory(dir, null); + long /*int*/ response = panel.runModalForDirectory(dir, null); if (parent != null && (style & SWT.SHEET) != 0) { application.endSheet(panel, 0); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java index cdc8ba5b94..428e197c7d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java @@ -151,7 +151,7 @@ public class Display extends Device { Menu[] menus, popups; NSApplication application; - int /*long*/ applicationClass; + long /*int*/ applicationClass; NSImage dockImage; boolean isEmbedded; static boolean launched = false; @@ -169,11 +169,11 @@ public class Display extends Device { int[] screenID = new int[32]; NSPoint[] screenCascade = new NSPoint[32]; - int /*long*/ runLoopObserver; + long /*int*/ runLoopObserver; Callback observerCallback; boolean lockCursor = true; - int /*long*/ oldCursorSetProc; + long /*int*/ oldCursorSetProc; Callback cursorSetCallback; boolean comboPoppedUp = false; @@ -208,9 +208,9 @@ public class Display extends Device { Cursor [] cursors = new Cursor [SWT.CURSOR_HAND + 1]; /* System Colors */ - float /*double*/ [][] colors; - float /*double*/ [] alternateSelectedControlTextColor, selectedControlTextColor; - float /*double*/ [] alternateSelectedControlColor, secondarySelectedControlColor; + double /*float*/ [][] colors; + double /*float*/ [] alternateSelectedControlTextColor, selectedControlTextColor; + double /*float*/ [] alternateSelectedControlColor, secondarySelectedControlColor; /* Key Mappings. */ static int [] [] KeyTable = { @@ -547,7 +547,7 @@ void addSkinnableWidget (Widget widget) { void addWidget (NSObject view, Widget widget) { if (view == null) return; - int /*long*/ ivar = OS.object_setInstanceVariable (view.id, SWT_OBJECT, widget.jniRef); + long /*int*/ ivar = OS.object_setInstanceVariable (view.id, SWT_OBJECT, widget.jniRef); if (ivar == 0) { if (dynamicObjectMap == null) { @@ -716,7 +716,7 @@ static void checkDisplay (Thread thread, boolean multiple) { } static NSRect convertRect(NSScreen screen, NSRect frame) { - float /*double*/ scaleFactor = screen.userSpaceScaleFactor(); + double /*float*/ scaleFactor = screen.userSpaceScaleFactor(); frame.x /= scaleFactor; frame.y /= scaleFactor; frame.width /= scaleFactor; @@ -854,7 +854,7 @@ void createDisplay (DeviceData data) { int [] psn = new int [2]; if (OS.GetCurrentProcess (psn) == OS.noErr) { int pid = OS.getpid (); - int /*long*/ ptr = getApplicationName().UTF8String(); + long /*int*/ ptr = getApplicationName().UTF8String(); if (ptr != 0) OS.CPSSetProcessName (psn, ptr); if (!isBundled ()) { OS.TransformProcessType (psn, OS.kProcessTransformToForegroundApplication); @@ -871,20 +871,20 @@ void createDisplay (DeviceData data) { } String className = "SWTApplication"; - int /*long*/ cls; + long /*int*/ cls; if ((cls = OS.objc_lookUpClass (className)) == 0) { Class clazz = getClass(); applicationCallback2 = new Callback(clazz, "applicationProc", 2); - int /*long*/ proc2 = applicationCallback2.getAddress(); + long /*int*/ proc2 = applicationCallback2.getAddress(); if (proc2 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); applicationCallback3 = new Callback(clazz, "applicationProc", 3); - int /*long*/ proc3 = applicationCallback3.getAddress(); + long /*int*/ proc3 = applicationCallback3.getAddress(); if (proc3 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); applicationCallback4 = new Callback(clazz, "applicationProc", 4); - int /*long*/ proc4 = applicationCallback4.getAddress(); + long /*int*/ proc4 = applicationCallback4.getAddress(); if (proc4 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); applicationCallback6 = new Callback(clazz, "applicationProc", 6); - int /*long*/ proc6 = applicationCallback6.getAddress(); + long /*int*/ proc6 = applicationCallback6.getAddress(); if (proc6 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); cls = OS.objc_allocateClassPair(OS.object_getClass(application.id), className, 0); OS.class_addMethod(cls, OS.sel_sendEvent_, proc3, "@:@"); @@ -897,10 +897,10 @@ void createDisplay (DeviceData data) { className = "SWTApplicationDelegate"; if (OS.objc_lookUpClass (className) == 0) { - int /*long*/ appProc3 = applicationCallback3.getAddress(); + long /*int*/ appProc3 = applicationCallback3.getAddress(); if (appProc3 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); cls = OS.objc_allocateClassPair(OS.class_NSObject, className, 0); - int /*long*/ appProc4 = applicationCallback4.getAddress(); + long /*int*/ appProc4 = applicationCallback4.getAddress(); if (appProc4 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); cls = OS.objc_allocateClassPair(OS.class_NSObject, className, 0); OS.class_addMethod(cls, OS.sel_applicationWillFinishLaunching_, appProc3, "@:@"); @@ -1002,7 +1002,7 @@ NSMutableArray currentTouches() { return currentTouches; } -int /*long*/ cursorSetProc (int /*long*/ id, int /*long*/ sel) { +long /*int*/ cursorSetProc (long /*int*/ id, long /*int*/ sel) { if (lockCursor) { if (currentControl != null) { Cursor cursor = currentControl.findCursor (); @@ -1103,7 +1103,7 @@ boolean filters (int eventType) { * * @noreference This method is not intended to be referenced by clients. */ -public Widget findWidget (int /*long*/ handle) { +public Widget findWidget (long /*int*/ handle) { checkDevice (); return getWidget (handle); } @@ -1132,7 +1132,7 @@ public Widget findWidget (int /*long*/ handle) { * * @since 3.1 */ -public Widget findWidget (int /*long*/ handle, int id) { +public Widget findWidget (long /*int*/ handle, int id) { checkDevice (); return getWidget (handle); } @@ -1267,14 +1267,14 @@ public Rectangle getBounds () { Rectangle getBounds (NSArray screens) { NSScreen screen = new NSScreen(screens.objectAtIndex(0)); NSRect primaryFrame = convertRect(screen, screen.frame()); - float /*double*/ minX = Float.MAX_VALUE, maxX = Float.MIN_VALUE; - float /*double*/ minY = Float.MAX_VALUE, maxY = Float.MIN_VALUE; - int /*long*/ count = screens.count(); + double /*float*/ minX = Float.MAX_VALUE, maxX = Float.MIN_VALUE; + double /*float*/ minY = Float.MAX_VALUE, maxY = Float.MIN_VALUE; + long /*int*/ count = screens.count(); for (int i = 0; i < count; i++) { screen = new NSScreen(screens.objectAtIndex(i)); NSRect frame = convertRect(screen, screen.frame()); - float /*double*/ x1 = frame.x, x2 = frame.x + frame.width; - float /*double*/ y1 = primaryFrame.height - frame.y, y2 = primaryFrame.height - (frame.y + frame.height); + double /*float*/ x1 = frame.x, x2 = frame.x + frame.width; + double /*float*/ y1 = primaryFrame.height - frame.y, y2 = primaryFrame.height - (frame.y + frame.height); if (x1 < minX) minX = x1; if (x2 < minX) minX = x2; if (x1 > maxX) maxX = x1; @@ -1323,7 +1323,7 @@ public Rectangle getClientArea () { NSScreen screen = new NSScreen(screens.objectAtIndex(0)); NSRect frame = convertRect(screen, screen.frame());; NSRect visibleFrame = convertRect(screen, screen.visibleFrame()); - float /*double*/ y = frame.height - (visibleFrame.y + visibleFrame.height); + double /*float*/ y = frame.height - (visibleFrame.y + visibleFrame.height); return new Rectangle((int)visibleFrame.x, (int)y, (int)visibleFrame.width, (int)visibleFrame.height); } @@ -1802,11 +1802,11 @@ Color getWidgetColor (int id) { return null; } -float /*double*/ [] getWidgetColorRGB (int id) { +double /*float*/ [] getWidgetColorRGB (int id) { NSColor color = null; switch (id) { case SWT.COLOR_INFO_FOREGROUND: color = NSColor.blackColor (); break; - case SWT.COLOR_INFO_BACKGROUND: return new float /*double*/ [] {.984f, .988f, 0.773f, 1}; + case SWT.COLOR_INFO_BACKGROUND: return new double /*float*/ [] {.984f, .988f, 0.773f, 1}; case SWT.COLOR_TITLE_FOREGROUND: color = NSColor.windowFrameTextColor(); break; case SWT.COLOR_TITLE_BACKGROUND: color = NSColor.alternateSelectedControlColor(); break; case SWT.COLOR_TITLE_BACKGROUND_GRADIENT: color = NSColor.selectedControlColor(); break; @@ -1828,16 +1828,16 @@ float /*double*/ [] getWidgetColorRGB (int id) { return getNSColorRGB (color); } -float /*double*/ [] getNSColorRGB (NSColor color) { +double /*float*/ [] getNSColorRGB (NSColor color) { if (color == null) return null; NSColorSpace colorSpace = color.colorSpace(); if (colorSpace == null || colorSpace.colorSpaceModel() != OS.NSRGBColorSpaceModel) { color = color.colorUsingColorSpaceName(OS.NSDeviceRGBColorSpace); } if (color == null) return null; - float /*double*/[] components = new float /*double*/[(int)/*64*/color.numberOfComponents()]; + double /*float*/[] components = new double /*float*/[(int)/*64*/color.numberOfComponents()]; color.getComponents(components); - return new float /*double*/ []{components[0], components[1], components[2], components[3]}; + return new double /*float*/ []{components[0], components[1], components[2], components[3]}; } /** @@ -1892,7 +1892,7 @@ public Cursor getSystemCursor (int id) { } NSImage getSystemImageForID(int osType) { - int /*long*/ iconRef[] = new int /*long*/ [1]; + long /*int*/ iconRef[] = new long /*int*/ [1]; OS.GetIconRefFromTypeInfo(OS.kSystemIconsCreator, osType, 0, 0, 0, iconRef); NSImage nsImage = (NSImage)new NSImage().alloc(); nsImage = nsImage.initWithIconRef(iconRef[0]); @@ -1998,7 +1998,7 @@ public Menu getSystemMenu () { appMenu = new Menu(this, nsAppMenu); // Create menu items that correspond to the NSMenuItems. - int /*long*/ nsCount = nsAppMenu.numberOfItems(); + long /*int*/ nsCount = nsAppMenu.numberOfItems(); for (int j = 0; j < nsCount; j++) { NSMenuItem currMenuItem = nsAppMenu.itemAtIndex(j); new MenuItem(appMenu, currMenuItem); @@ -2085,14 +2085,14 @@ int getToolTipTime () { return 560; } -Widget getWidget (int /*long*/ id) { +Widget getWidget (long /*int*/ id) { return GetWidget (id); } -static Widget GetWidget (int /*long*/ id) { +static Widget GetWidget (long /*int*/ id) { if (id == 0) return null; - int /*long*/ [] jniRef = new int /*long*/ [1]; - int /*long*/ iVar = OS.object_getInstanceVariable(id, SWT_OBJECT, jniRef); + long /*int*/ [] jniRef = new long /*int*/ [1]; + long /*int*/ iVar = OS.object_getInstanceVariable(id, SWT_OBJECT, jniRef); if (iVar == 0) { if (dynamicObjectMap != null) { NSObject key = new NSObject(id); @@ -2112,7 +2112,7 @@ Widget getWidget (NSView view) { boolean hasDefaultButton () { NSArray windows = application.windows(); - int /*long*/ count = windows.count(); + long /*int*/ count = windows.count(); for (int i = 0; i < count; i++) { NSWindow window = new NSWindow(windows.objectAtIndex(i)); if (window.defaultButtonCell() != null) { @@ -2146,7 +2146,7 @@ protected void init () { if (currAppDelegate == null) { if (OS.class_JRSAppKitAWT != 0) { - int /*long*/ currDelegatePtr = OS.objc_msgSend(OS.class_JRSAppKitAWT, OS.sel_awtAppDelegate); + long /*int*/ currDelegatePtr = OS.objc_msgSend(OS.class_JRSAppKitAWT, OS.sel_awtAppDelegate); if (currDelegatePtr != 0) { currAppDelegate = new NSObject(currDelegatePtr); currAppDelegate.retain(); @@ -2190,7 +2190,7 @@ protected void init () { if (prefsItem != null) prefsItem.setTag(SWT.ID_PREFERENCES); observerCallback = new Callback (this, "observerProc", 3); //$NON-NLS-1$ - int /*long*/ observerProc = observerCallback.getAddress (); + long /*int*/ observerProc = observerCallback.getAddress (); if (observerProc == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); int activities = OS.kCFRunLoopBeforeWaiting; runLoopObserver = OS.CFRunLoopObserverCreate (0, activities, true, 0, observerProc, 0); @@ -2198,18 +2198,18 @@ protected void init () { OS.CFRunLoopAddObserver (OS.CFRunLoopGetCurrent (), runLoopObserver, OS.kCFRunLoopCommonModes ()); // Add AWT Runloop mode for SWT/AWT. - int /*long*/ cls = OS.objc_lookUpClass("JNFRunLoop"); //$NON-NLS-1$ + long /*int*/ cls = OS.objc_lookUpClass("JNFRunLoop"); //$NON-NLS-1$ if (cls != 0) { - int /*long*/ mode = OS.objc_msgSend(cls, OS.sel_javaRunLoopMode); + long /*int*/ mode = OS.objc_msgSend(cls, OS.sel_javaRunLoopMode); if (mode != 0) { OS.CFRunLoopAddObserver (OS.CFRunLoopGetCurrent (), runLoopObserver, mode); } } cursorSetCallback = new Callback(this, "cursorSetProc", 2); - int /*long*/ cursorSetProc = cursorSetCallback.getAddress(); + long /*int*/ cursorSetProc = cursorSetCallback.getAddress(); if (cursorSetProc == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); - int /*long*/ method = OS.class_getInstanceMethod(OS.class_NSCursor, OS.sel_set); + long /*int*/ method = OS.class_getInstanceMethod(OS.class_NSCursor, OS.sel_set); if (method != 0) oldCursorSetProc = OS.method_setImplementation(method, cursorSetProc); timerDelegate = (SWTWindowDelegate)new SWTWindowDelegate().alloc().init(); @@ -2233,7 +2233,7 @@ protected void init () { isPainting = isPainting.initWithCapacity(12); } -void addEventMethods (int /*long*/ cls, int /*long*/ proc2, int /*long*/ proc3, int /*long*/ drawRectProc, int /*long*/ hitTestProc, int /*long*/ needsDisplayInRectProc) { +void addEventMethods (long /*int*/ cls, long /*int*/ proc2, long /*int*/ proc3, long /*int*/ drawRectProc, long /*int*/ hitTestProc, long /*int*/ needsDisplayInRectProc) { if (proc3 != 0) { OS.class_addMethod(cls, OS.sel_mouseDown_, proc3, "@:@"); OS.class_addMethod(cls, OS.sel_mouseUp_, proc3, "@:@"); @@ -2288,12 +2288,12 @@ void addEventMethods (int /*long*/ cls, int /*long*/ proc2, int /*long*/ proc3, } } -void addFrameMethods(int /*long*/ cls, int /*long*/ setFrameOriginProc, int /*long*/ setFrameSizeProc) { +void addFrameMethods(long /*int*/ cls, long /*int*/ setFrameOriginProc, long /*int*/ setFrameSizeProc) { OS.class_addMethod(cls, OS.sel_setFrameOrigin_, setFrameOriginProc, "@:{NSPoint}"); OS.class_addMethod(cls, OS.sel_setFrameSize_, setFrameSizeProc, "@:{NSSize}"); } -void addAccessibilityMethods(int /*long*/ cls, int /*long*/ proc2, int /*long*/ proc3, int /*long*/ proc4, int /*long*/ accessibilityHitTestProc) { +void addAccessibilityMethods(long /*int*/ cls, long /*int*/ proc2, long /*int*/ proc3, long /*int*/ proc4, long /*int*/ accessibilityHitTestProc) { OS.class_addMethod(cls, OS.sel_accessibilityActionNames, proc2, "@:"); OS.class_addMethod(cls, OS.sel_accessibilityAttributeNames, proc2, "@:"); OS.class_addMethod(cls, OS.sel_accessibilityParameterizedAttributeNames, proc2, "@:"); @@ -2309,24 +2309,24 @@ void addAccessibilityMethods(int /*long*/ cls, int /*long*/ proc2, int /*long*/ OS.class_addMethod(cls, OS.sel_accessibleHandle, proc2, "@:"); } -int /*long*/ registerCellSubclass(int /*long*/ cellClass, int size, int align, byte[] types) { +long /*int*/ registerCellSubclass(long /*int*/ cellClass, int size, int align, byte[] types) { String cellClassName = OS.class_getName(cellClass); - int /*long*/ cls = OS.objc_allocateClassPair(cellClass, "SWTAccessible" + cellClassName, 0); + long /*int*/ cls = OS.objc_allocateClassPair(cellClass, "SWTAccessible" + cellClassName, 0); OS.class_addIvar(cls, SWT_OBJECT, size, (byte)align, types); OS.objc_registerClassPair(cls); return cls; } -int /*long*/ createWindowSubclass(int /*long*/ baseClass, String newClass, boolean isDynamic) { - int /*long*/ cls = OS.objc_lookUpClass(newClass); +long /*int*/ createWindowSubclass(long /*int*/ baseClass, String newClass, boolean isDynamic) { + long /*int*/ cls = OS.objc_lookUpClass(newClass); if (cls != 0) return cls; cls = OS.objc_allocateClassPair(baseClass, newClass, 0); - int /*long*/ proc3 = windowCallback3.getAddress(); - int /*long*/ proc2 = windowCallback2.getAddress(); - int /*long*/ proc4 = windowCallback4.getAddress(); - int /*long*/ proc6 = windowCallback6.getAddress(); - int /*long*/ view_stringForToolTip_point_userDataProc = OS.CALLBACK_view_stringForToolTip_point_userData_(proc6); - int /*long*/ accessibilityHitTestProc = OS.CALLBACK_accessibilityHitTest_(proc3); + long /*int*/ proc3 = windowCallback3.getAddress(); + long /*int*/ proc2 = windowCallback2.getAddress(); + long /*int*/ proc4 = windowCallback4.getAddress(); + long /*int*/ proc6 = windowCallback6.getAddress(); + long /*int*/ view_stringForToolTip_point_userDataProc = OS.CALLBACK_view_stringForToolTip_point_userData_(proc6); + long /*int*/ accessibilityHitTestProc = OS.CALLBACK_accessibilityHitTest_(proc3); if (!isDynamic) OS.class_addIvar(cls, SWT_OBJECT, size, (byte)align, types); OS.class_addMethod(cls, OS.sel_sendEvent_, proc3, "@:@"); @@ -2341,12 +2341,12 @@ int /*long*/ createWindowSubclass(int /*long*/ baseClass, String newClass, boole return cls; } -int /*long*/ createMenuSubclass(int /*long*/ baseClass, String newClass, boolean isDynamic) { - int /*long*/ cls = OS.objc_lookUpClass(newClass); +long /*int*/ createMenuSubclass(long /*int*/ baseClass, String newClass, boolean isDynamic) { + long /*int*/ cls = OS.objc_lookUpClass(newClass); if (cls != 0) return cls; cls = OS.objc_allocateClassPair(baseClass, newClass, 0); - int /*long*/ proc3 = windowCallback3.getAddress(); - int /*long*/ proc4 = windowCallback4.getAddress(); + long /*int*/ proc3 = windowCallback3.getAddress(); + long /*int*/ proc4 = windowCallback4.getAddress(); OS.class_addIvar(cls, SWT_OBJECT, size, (byte)align, types); OS.class_addMethod(cls, OS.sel_menuWillOpen_, proc3, "@:@"); OS.class_addMethod(cls, OS.sel_menuDidClose_, proc3, "@:@"); @@ -2356,11 +2356,11 @@ int /*long*/ createMenuSubclass(int /*long*/ baseClass, String newClass, boolean return cls; } -int /*long*/ createMenuItemSubclass(int /*long*/ baseClass, String newClass, boolean isDynamic) { - int /*long*/ cls = OS.objc_lookUpClass(newClass); +long /*int*/ createMenuItemSubclass(long /*int*/ baseClass, String newClass, boolean isDynamic) { + long /*int*/ cls = OS.objc_lookUpClass(newClass); if (cls != 0) return cls; cls = OS.objc_allocateClassPair(baseClass, newClass, 0); - int /*long*/ proc2 = windowCallback2.getAddress(); + long /*int*/ proc2 = windowCallback2.getAddress(); if (!isDynamic) OS.class_addIvar(cls, SWT_OBJECT, size, (byte)align, types); OS.class_addMethod(cls, OS.sel_sendSelection, proc2, "@:"); OS.objc_registerClassPair(cls); @@ -2372,68 +2372,68 @@ void initClasses () { Class clazz = getClass (); dialogCallback3 = new Callback(clazz, "dialogProc", 3); - int /*long*/ dialogProc3 = dialogCallback3.getAddress(); + long /*int*/ dialogProc3 = dialogCallback3.getAddress(); if (dialogProc3 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); dialogCallback4 = new Callback(clazz, "dialogProc", 4); - int /*long*/ dialogProc4 = dialogCallback4.getAddress(); + long /*int*/ dialogProc4 = dialogCallback4.getAddress(); if (dialogProc4 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); dialogCallback5 = new Callback(clazz, "dialogProc", 5); - int /*long*/ dialogProc5 = dialogCallback5.getAddress(); + long /*int*/ dialogProc5 = dialogCallback5.getAddress(); if (dialogProc5 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); windowCallback3 = new Callback(clazz, "windowProc", 3); - int /*long*/ proc3 = windowCallback3.getAddress(); + long /*int*/ proc3 = windowCallback3.getAddress(); if (proc3 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); windowCallback2 = new Callback(clazz, "windowProc", 2); - int /*long*/ proc2 = windowCallback2.getAddress(); + long /*int*/ proc2 = windowCallback2.getAddress(); if (proc2 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); windowCallback4 = new Callback(clazz, "windowProc", 4); - int /*long*/ proc4 = windowCallback4.getAddress(); + long /*int*/ proc4 = windowCallback4.getAddress(); if (proc4 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); windowCallback5 = new Callback(clazz, "windowProc", 5); - int /*long*/ proc5 = windowCallback5.getAddress(); + long /*int*/ proc5 = windowCallback5.getAddress(); if (proc5 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); windowCallback6 = new Callback(clazz, "windowProc", 6); - int /*long*/ proc6 = windowCallback6.getAddress(); + long /*int*/ proc6 = windowCallback6.getAddress(); if (proc6 == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); - int /*long*/ isFlippedProc = OS.isFlipped_CALLBACK(); - int /*long*/ drawRectProc = OS.CALLBACK_drawRect_(proc3); - int /*long*/ drawInteriorWithFrameInViewProc = OS.CALLBACK_drawInteriorWithFrame_inView_ (proc4); - int /*long*/ drawWithExpansionFrameProc = OS.CALLBACK_drawWithExpansionFrame_inView_ (proc4); - int /*long*/ imageRectForBoundsProc = OS.CALLBACK_imageRectForBounds_ (proc3); - int /*long*/ titleRectForBoundsProc = OS.CALLBACK_titleRectForBounds_ (proc3); - int /*long*/ cellSizeForBoundsProc = OS.CALLBACK_cellSizeForBounds_ (proc3); - int /*long*/ hitTestForEvent_inRect_ofViewProc = OS.CALLBACK_hitTestForEvent_inRect_ofView_ (proc5); - int /*long*/ cellSizeProc = OS.CALLBACK_cellSize (proc2); - int /*long*/ drawImageWithFrameInViewProc = OS.CALLBACK_drawImage_withFrame_inView_ (proc5); - int /*long*/ drawTitleWithFrameInViewProc = OS.CALLBACK_drawTitle_withFrame_inView_ (proc5); - int /*long*/ setFrameOriginProc = OS.CALLBACK_setFrameOrigin_(proc3); - int /*long*/ setFrameSizeProc = OS.CALLBACK_setFrameSize_(proc3); - int /*long*/ hitTestProc = OS.CALLBACK_hitTest_(proc3); - int /*long*/ markedRangeProc = OS.CALLBACK_markedRange (proc2); - int /*long*/ selectedRangeProc = OS.CALLBACK_selectedRange (proc2); - int /*long*/ highlightSelectionInClipRectProc = OS.CALLBACK_highlightSelectionInClipRect_ (proc3); - int /*long*/ setMarkedText_selectedRangeProc = OS.CALLBACK_setMarkedText_selectedRange_(proc4); - int /*long*/ attributedSubstringFromRangeProc = OS.CALLBACK_attributedSubstringFromRange_(proc3); - int /*long*/ characterIndexForPointProc = OS.CALLBACK_characterIndexForPoint_(proc3); - int /*long*/ firstRectForCharacterRangeProc = OS.CALLBACK_firstRectForCharacterRange_(proc3); - int /*long*/ textWillChangeSelectionProc = OS.CALLBACK_textView_willChangeSelectionFromCharacterRange_toCharacterRange_(proc5); - int /*long*/ accessibilityHitTestProc = OS.CALLBACK_accessibilityHitTest_(proc3); - int /*long*/ shouldChangeTextInRange_replacementString_Proc = OS.CALLBACK_shouldChangeTextInRange_replacementString_(proc4); - int /*long*/ view_stringForToolTip_point_userDataProc = OS.CALLBACK_view_stringForToolTip_point_userData_(proc6); - int /*long*/ canDragRowsWithIndexes_atPoint_Proc = OS.CALLBACK_canDragRowsWithIndexes_atPoint_(proc4); - int /*long*/ setNeedsDisplayInRectProc = OS.CALLBACK_setNeedsDisplayInRect_(proc3); - int /*long*/ expansionFrameWithFrameProc = OS.CALLBACK_expansionFrameWithFrame_inView_ (proc4); - int /*long*/ sizeOfLabelProc = OS.CALLBACK_sizeOfLabel_ (proc3); - int /*long*/ drawLabelInRectProc = OS.CALLBACK_drawLabel_inRect_ (proc4); - int /*long*/ drawViewBackgroundInRectProc = OS.CALLBACK_drawViewBackgroundInRect_(proc3); - int /*long*/ drawBackgroundInClipRectProc = OS.CALLBACK_drawBackgroundInClipRect_(proc3); - int /*long*/ scrollClipView_ToPointProc = OS.CALLBACK_scrollClipView_toPoint_(proc4); - int /*long*/ headerRectOfColumnProc = OS.CALLBACK_headerRectOfColumn_(proc3); - int /*long*/ columnAtPointProc = OS.CALLBACK_columnAtPoint_(proc3); + long /*int*/ isFlippedProc = OS.isFlipped_CALLBACK(); + long /*int*/ drawRectProc = OS.CALLBACK_drawRect_(proc3); + long /*int*/ drawInteriorWithFrameInViewProc = OS.CALLBACK_drawInteriorWithFrame_inView_ (proc4); + long /*int*/ drawWithExpansionFrameProc = OS.CALLBACK_drawWithExpansionFrame_inView_ (proc4); + long /*int*/ imageRectForBoundsProc = OS.CALLBACK_imageRectForBounds_ (proc3); + long /*int*/ titleRectForBoundsProc = OS.CALLBACK_titleRectForBounds_ (proc3); + long /*int*/ cellSizeForBoundsProc = OS.CALLBACK_cellSizeForBounds_ (proc3); + long /*int*/ hitTestForEvent_inRect_ofViewProc = OS.CALLBACK_hitTestForEvent_inRect_ofView_ (proc5); + long /*int*/ cellSizeProc = OS.CALLBACK_cellSize (proc2); + long /*int*/ drawImageWithFrameInViewProc = OS.CALLBACK_drawImage_withFrame_inView_ (proc5); + long /*int*/ drawTitleWithFrameInViewProc = OS.CALLBACK_drawTitle_withFrame_inView_ (proc5); + long /*int*/ setFrameOriginProc = OS.CALLBACK_setFrameOrigin_(proc3); + long /*int*/ setFrameSizeProc = OS.CALLBACK_setFrameSize_(proc3); + long /*int*/ hitTestProc = OS.CALLBACK_hitTest_(proc3); + long /*int*/ markedRangeProc = OS.CALLBACK_markedRange (proc2); + long /*int*/ selectedRangeProc = OS.CALLBACK_selectedRange (proc2); + long /*int*/ highlightSelectionInClipRectProc = OS.CALLBACK_highlightSelectionInClipRect_ (proc3); + long /*int*/ setMarkedText_selectedRangeProc = OS.CALLBACK_setMarkedText_selectedRange_(proc4); + long /*int*/ attributedSubstringFromRangeProc = OS.CALLBACK_attributedSubstringFromRange_(proc3); + long /*int*/ characterIndexForPointProc = OS.CALLBACK_characterIndexForPoint_(proc3); + long /*int*/ firstRectForCharacterRangeProc = OS.CALLBACK_firstRectForCharacterRange_(proc3); + long /*int*/ textWillChangeSelectionProc = OS.CALLBACK_textView_willChangeSelectionFromCharacterRange_toCharacterRange_(proc5); + long /*int*/ accessibilityHitTestProc = OS.CALLBACK_accessibilityHitTest_(proc3); + long /*int*/ shouldChangeTextInRange_replacementString_Proc = OS.CALLBACK_shouldChangeTextInRange_replacementString_(proc4); + long /*int*/ view_stringForToolTip_point_userDataProc = OS.CALLBACK_view_stringForToolTip_point_userData_(proc6); + long /*int*/ canDragRowsWithIndexes_atPoint_Proc = OS.CALLBACK_canDragRowsWithIndexes_atPoint_(proc4); + long /*int*/ setNeedsDisplayInRectProc = OS.CALLBACK_setNeedsDisplayInRect_(proc3); + long /*int*/ expansionFrameWithFrameProc = OS.CALLBACK_expansionFrameWithFrame_inView_ (proc4); + long /*int*/ sizeOfLabelProc = OS.CALLBACK_sizeOfLabel_ (proc3); + long /*int*/ drawLabelInRectProc = OS.CALLBACK_drawLabel_inRect_ (proc4); + long /*int*/ drawViewBackgroundInRectProc = OS.CALLBACK_drawViewBackgroundInRect_(proc3); + long /*int*/ drawBackgroundInClipRectProc = OS.CALLBACK_drawBackgroundInClipRect_(proc3); + long /*int*/ scrollClipView_ToPointProc = OS.CALLBACK_scrollClipView_toPoint_(proc4); + long /*int*/ headerRectOfColumnProc = OS.CALLBACK_headerRectOfColumn_(proc3); + long /*int*/ columnAtPointProc = OS.CALLBACK_columnAtPoint_(proc3); String className; - int /*long*/ cls; + long /*int*/ cls; className = "SWTBox"; cls = OS.objc_allocateClassPair(OS.class_NSBox, className, 0); @@ -2657,7 +2657,7 @@ void initClasses () { OS.objc_registerClassPair(cls); if (OS.VERSION >= 0x1070) { /* Note that isFlippedProc is used for performance and convenience */ - int /*long*/ metaClass = OS.objc_getMetaClass(className); + long /*int*/ metaClass = OS.objc_getMetaClass(className); OS.class_addMethod(metaClass, OS.sel_isCompatibleWithOverlayScrollers, isFlippedProc, "@:"); } @@ -2704,7 +2704,7 @@ void initClasses () { OS.class_addMethod(cls, OS.sel_textView_willChangeSelectionFromCharacterRange_toCharacterRange_, textWillChangeSelectionProc, "@:@{NSRange}{NSRange}"); OS.objc_registerClassPair(cls); - int /*long*/ nsSecureTextViewClass = OS.objc_lookUpClass("NSSecureTextView"); + long /*int*/ nsSecureTextViewClass = OS.objc_lookUpClass("NSSecureTextView"); if (nsSecureTextViewClass != 0) { className = "SWTSecureEditorView"; cls = OS.objc_allocateClassPair(nsSecureTextViewClass, className, 0); @@ -2910,9 +2910,9 @@ void initClasses () { OS.objc_registerClassPair(cls); } -NSFont getFont (int /*long*/ cls, int /*long*/ sel) { - int /*long*/ widget = OS.objc_msgSend (OS.objc_msgSend (cls, OS.sel_alloc), OS.sel_initWithFrame_, new NSRect()); - int /*long*/ font = 0; +NSFont getFont (long /*int*/ cls, long /*int*/ sel) { + long /*int*/ widget = OS.objc_msgSend (OS.objc_msgSend (cls, OS.sel_alloc), OS.sel_initWithFrame_, new NSRect()); + long /*int*/ font = 0; if (OS.objc_msgSend_bool (widget, OS.sel_respondsToSelector_, sel)) { font = OS.objc_msgSend (widget, sel); } @@ -2928,7 +2928,7 @@ NSFont getFont (int /*long*/ cls, int /*long*/ sel) { } void initColors () { - colors = new float /*double*/ [SWT.COLOR_TITLE_INACTIVE_BACKGROUND_GRADIENT + 1][]; + colors = new double /*float*/ [SWT.COLOR_TITLE_INACTIVE_BACKGROUND_GRADIENT + 1][]; colors[SWT.COLOR_INFO_FOREGROUND] = getWidgetColorRGB(SWT.COLOR_INFO_FOREGROUND); colors[SWT.COLOR_INFO_BACKGROUND] = getWidgetColorRGB(SWT.COLOR_INFO_BACKGROUND); colors[SWT.COLOR_TITLE_FOREGROUND] = getWidgetColorRGB(SWT.COLOR_TITLE_FOREGROUND); @@ -2996,7 +2996,7 @@ void initFonts () { * * @noreference This method is not intended to be referenced by clients. */ -public int /*long*/ internal_new_GC (GCData data) { +public long /*int*/ internal_new_GC (GCData data) { if (isDisposed()) error(SWT.ERROR_DEVICE_DISPOSED); if (screenWindow == null) { NSWindow window = (NSWindow) new NSWindow ().alloc (); @@ -3039,7 +3039,7 @@ public int /*long*/ internal_new_GC (GCData data) { * * @noreference This method is not intended to be referenced by clients. */ -public void internal_dispose_GC (int /*long*/ hDC, GCData data) { +public void internal_dispose_GC (long /*int*/ hDC, GCData data) { if (isDisposed()) error(SWT.ERROR_DEVICE_DISPOSED); } @@ -3128,8 +3128,8 @@ public boolean post(Event event) { synchronized (Device.class) { if (isDisposed ()) error (SWT.ERROR_DEVICE_DISPOSED); if (event == null) error (SWT.ERROR_NULL_ARGUMENT); - int /*long*/ eventRef = 0; - int /*long*/ eventSource = OS.CGEventSourceCreate(OS.kCGEventSourceStateHIDSystemState); + long /*int*/ eventRef = 0; + long /*int*/ eventSource = OS.CGEventSourceCreate(OS.kCGEventSourceStateHIDSystemState); if (eventSource == 0) return false; boolean returnValue = false; int deadKeyState[] = new int[1]; @@ -3139,9 +3139,9 @@ public boolean post(Event event) { case SWT.KeyUp: { short vKey = (short)Display.untranslateKey (event.keyCode); if (vKey == 0) { - int /*long*/ uchrPtr = 0; - int /*long*/ currentKbd = OS.TISCopyCurrentKeyboardInputSource(); - int /*long*/ uchrCFData = OS.TISGetInputSourceProperty(currentKbd, OS.kTISPropertyUnicodeKeyLayoutData()); + long /*int*/ uchrPtr = 0; + long /*int*/ currentKbd = OS.TISCopyCurrentKeyboardInputSource(); + long /*int*/ uchrCFData = OS.TISGetInputSourceProperty(currentKbd, OS.kTISPropertyUnicodeKeyLayoutData()); if (uchrCFData == 0) return false; uchrPtr = OS.CFDataGetBytePtr(uchrCFData); @@ -3385,13 +3385,13 @@ public Point map (Control from, Control to, int x, int y) { pt = view.convertPoint_toView_(pt, null); pt = fromWindow.convertBaseToScreen(pt); pt.y = primaryFrame.height - pt.y; - float /*double*/ scaleFactor = fromWindow.userSpaceScaleFactor(); + double /*float*/ scaleFactor = fromWindow.userSpaceScaleFactor(); pt.x /= scaleFactor; pt.y /= scaleFactor; } if (to != null) { NSView view = to.eventView (); - float /*double*/ scaleFactor = toWindow.userSpaceScaleFactor(); + double /*float*/ scaleFactor = toWindow.userSpaceScaleFactor(); pt.x *= scaleFactor; pt.y = primaryFrame.height - (pt.y * scaleFactor); pt = toWindow.convertScreenToBase(pt); @@ -3515,13 +3515,13 @@ public Rectangle map (Control from, Control to, int x, int y, int width, int hei pt = view.convertPoint_toView_(pt, null); pt = fromWindow.convertBaseToScreen(pt); pt.y = primaryFrame.height - pt.y; - float /*double*/ scaleFactor = fromWindow.userSpaceScaleFactor(); + double /*float*/ scaleFactor = fromWindow.userSpaceScaleFactor(); pt.x /= scaleFactor; pt.y /= scaleFactor; } if (to != null) { NSView view = to.eventView (); - float /*double*/ scaleFactor = toWindow.userSpaceScaleFactor(); + double /*float*/ scaleFactor = toWindow.userSpaceScaleFactor(); pt.x *= scaleFactor; pt.y = primaryFrame.height - (pt.y * scaleFactor); pt = toWindow.convertScreenToBase(pt); @@ -3536,7 +3536,7 @@ public Rectangle map (Control from, Control to, int x, int y, int width, int hei return rectangle; } -int /*long*/ observerProc (int /*long*/ observer, int /*long*/ activity, int /*long*/ info) { +long /*int*/ observerProc (long /*int*/ observer, long /*int*/ activity, long /*int*/ info) { switch ((int)/*64*/activity) { case OS.kCFRunLoopBeforeWaiting: if (runAsyncMessages) { @@ -3551,8 +3551,8 @@ boolean performKeyEquivalent(NSWindow window, NSEvent nsEvent) { if (modalDialog == null) return false; if (nsEvent.type() != OS.NSKeyDown) return false; int stateMask = 0; - int /*long*/ selector = 0; - int /*long*/ modifierFlags = nsEvent.modifierFlags(); + long /*int*/ selector = 0; + long /*int*/ modifierFlags = nsEvent.modifierFlags(); if ((modifierFlags & OS.NSAlternateKeyMask) != 0) stateMask |= SWT.ALT; if ((modifierFlags & OS.NSShiftKeyMask) != 0) stateMask |= SWT.SHIFT; if ((modifierFlags & OS.NSControlKeyMask) != 0) stateMask |= SWT.CONTROL; @@ -3780,7 +3780,7 @@ void releaseDisplay () { markedAttributes = null; if (oldCursorSetProc != 0) { - int /*long*/ method = OS.class_getInstanceMethod(OS.class_NSCursor, OS.sel_set); + long /*int*/ method = OS.class_getInstanceMethod(OS.class_NSCursor, OS.sel_set); OS.method_setImplementation(method, oldCursorSetProc); } if (cursorSetCallback != null) cursorSetCallback.dispose(); @@ -3796,7 +3796,7 @@ void releaseDisplay () { if (!isEmbedded) { //remove all existing menu items except the application menu NSMenu menubar = application.mainMenu(); - int /*long*/ count = menubar.numberOfItems(); + long /*int*/ count = menubar.numberOfItems(); while (count > 1) { menubar.removeItemAtIndex(count - 1); count--; @@ -3902,8 +3902,8 @@ public void removeListener (int eventType, Listener listener) { Widget removeWidget (NSObject view) { if (view == null) return null; - int /*long*/ [] jniRef = new int /*long*/ [1]; - int /*long*/ iVar = OS.object_getInstanceVariable(view.id, SWT_OBJECT, jniRef); + long /*int*/ [] jniRef = new long /*int*/ [1]; + long /*int*/ iVar = OS.object_getInstanceVariable(view.id, SWT_OBJECT, jniRef); if (iVar == 0) { if (dynamicObjectMap != null) { @@ -4034,7 +4034,7 @@ NSArray runLoopModes() { boolean runPaint () { if (needsDisplay == null && needsDisplayInRect == null) return false; if (needsDisplay != null) { - int /*long*/ count = needsDisplay.count(); + long /*int*/ count = needsDisplay.count(); for (int i = 0; i < count; i++) { OS.objc_msgSend(needsDisplay.objectAtIndex(i).id, OS.sel_setNeedsDisplay_, true); } @@ -4042,7 +4042,7 @@ boolean runPaint () { needsDisplay = null; } if (needsDisplayInRect != null) { - int /*long*/ count = needsDisplayInRect.count(); + long /*int*/ count = needsDisplayInRect.count(); for (int i = 0; i < count; i+=2) { NSValue value = new NSValue(needsDisplayInRect.objectAtIndex(i+1)); OS.objc_msgSend(needsDisplayInRect.objectAtIndex(i).id, OS.sel_setNeedsDisplayInRect_, value.rectValue()); @@ -4150,7 +4150,7 @@ void sendEvent (EventTable table, Event event) { static NSString getApplicationName() { NSString name = null; int pid = OS.getpid (); - int /*long*/ ptr = OS.getenv (ascii ("APP_NAME_" + pid)); + long /*int*/ ptr = OS.getenv (ascii ("APP_NAME_" + pid)); if (ptr != 0) name = NSString.stringWithUTF8String(ptr); if (name == null && APP_NAME != null) name = NSString.stringWith(APP_NAME); if (name == null) { @@ -4446,7 +4446,7 @@ void setMenuBar (Menu menu) { */ // menubar.cancelTracking(); OS.CancelMenuTracking (OS.AcquireRootMenu (), true, 0); - int /*long*/ count = menubar.numberOfItems(); + long /*int*/ count = menubar.numberOfItems(); while (count > 1) { menubar.removeItemAtIndex(count - 1); count--; @@ -4693,7 +4693,7 @@ public void timerExec (int milliseconds, Runnable runnable) { } } -int /*long*/ timerProc (int /*long*/ id, int /*long*/ sel, int /*long*/ timerID) { +long /*int*/ timerProc (long /*int*/ id, long /*int*/ sel, long /*int*/ timerID) { NSTimer timer = new NSTimer (timerID); try { NSNumber number = new NSNumber(timer.userInfo()); @@ -4761,7 +4761,7 @@ void updateQuitMenu () { NSMenu sm = appitem.submenu(); // Normally this would be sel_terminate_ but we changed it so terminate: doesn't kill the app. - int /*long*/ quitIndex = sm.indexOfItemWithTarget(applicationDelegate, OS.sel_applicationShouldTerminate_); + long /*int*/ quitIndex = sm.indexOfItemWithTarget(applicationDelegate, OS.sel_applicationShouldTerminate_); if (quitIndex != -1) { NSMenuItem quitItem = sm.itemAtIndex(quitIndex); @@ -4803,12 +4803,12 @@ Control findControl (boolean checkTrim) { Control findControl (boolean checkTrim, NSView[] hitView) { NSView view = null; NSPoint screenLocation = NSEvent.mouseLocation(); - int /*long*/ hitWindowNumber = 0; + long /*int*/ hitWindowNumber = 0; if (OS.VERSION >= 0x1060) { hitWindowNumber = NSWindow.windowNumberAtPoint(screenLocation, 0); } else { - int /*long*/ outWindow[] = new int /*long*/ [1]; - OS.FindWindow ((int /*long*/)screenLocation.x, (int /*long*/)(getPrimaryFrame().height - screenLocation.y), outWindow); + long /*int*/ outWindow[] = new long /*int*/ [1]; + OS.FindWindow ((long /*int*/)screenLocation.x, (long /*int*/)(getPrimaryFrame().height - screenLocation.y), outWindow); if (outWindow[0] != 0) { hitWindowNumber = OS.HIWindowGetCGWindowID(outWindow[0]); @@ -4846,7 +4846,7 @@ Control findControl (boolean checkTrim, NSView[] hitView) { return control; } -void finishLaunching (int /*long*/ id, int /*long*/ sel) { +void finishLaunching (long /*int*/ id, long /*int*/ sel) { /* * [NSApplication finishLaunching] cannot run multiple times otherwise * multiple main menus are added. @@ -4859,7 +4859,7 @@ void finishLaunching (int /*long*/ id, int /*long*/ sel) { OS.objc_msgSendSuper(super_struct, sel); } -void applicationDidBecomeActive (int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void applicationDidBecomeActive (long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { NSWindow keyWindow = application.keyWindow(); if (keyWindow != null) { keyWindow.orderFrontRegardless(); @@ -4870,17 +4870,17 @@ void applicationDidBecomeActive (int /*long*/ id, int /*long*/ sel, int /*long*/ checkEnterExit(findControl(true), null, false); } -void applicationDidResignActive (int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void applicationDidResignActive (long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { checkFocus(); checkEnterExit(null, null, false); } -int /*long*/ applicationNextEventMatchingMask (int /*long*/ id, int /*long*/ sel, int /*long*/ mask, int /*long*/ expiration, int /*long*/ mode, int /*long*/ dequeue) { +long /*int*/ applicationNextEventMatchingMask (long /*int*/ id, long /*int*/ sel, long /*int*/ mask, long /*int*/ expiration, long /*int*/ mode, long /*int*/ dequeue) { if (dequeue != 0 && trackingControl != null && !trackingControl.isDisposed()) runDeferredEvents(); objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); - int /*long*/ result = OS.objc_msgSendSuper(super_struct, sel, mask, expiration, mode, dequeue != 0); + long /*int*/ result = OS.objc_msgSendSuper(super_struct, sel, mask, expiration, mode, dequeue != 0); if (result != 0) { /* * Feature of Cocoa. When an NSComboBox's items list is visible it runs an event @@ -4944,7 +4944,7 @@ void applicationSendTrackingEvent (NSEvent nsEvent, Control trackingControl) { } } -void applicationSendEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void applicationSendEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { NSEvent nsEvent = new NSEvent(event); NSWindow window = nsEvent.window (); @@ -5014,7 +5014,7 @@ void applicationSendEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event if (type != OS.NSAppKitDefined) sendEvent = false; } -void applicationWillFinishLaunching (int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void applicationWillFinishLaunching (long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { boolean loaded = false; /* @@ -5027,7 +5027,7 @@ void applicationWillFinishLaunching (int /*long*/ id, int /*long*/ sel, int /*lo * return a non-zero value indicating failure, which we ignore. */ if (isEmbedded) { - int /*long*/ outMenu [] = new int /*long*/ [1]; + long /*int*/ outMenu [] = new long /*int*/ [1]; short outIndex[] = new short[1]; int status = OS.GetIndMenuItemWithCommandID(0, OS.kHICommandHide, 1, outMenu, outIndex); if (status == 0) OS.DeleteMenuItem(outMenu[0], outIndex[0]); @@ -5090,7 +5090,7 @@ void applicationWillFinishLaunching (int /*long*/ id, int /*long*/ sel, int /*lo NSMenuItem ni = new NSMenuItem(ia.objectAtIndex(i)); NSString title = ni.title().stringByReplacingOccurrencesOfString(match, name); ni.setTitle(title); - int /*long*/ newTag = 0; + long /*int*/ newTag = 0; switch(i) { case 0: newTag = SWT.ID_ABOUT; @@ -5114,7 +5114,7 @@ void applicationWillFinishLaunching (int /*long*/ id, int /*long*/ sel, int /*lo if (newTag != 0) ni.setTag(newTag); } - int /*long*/ quitIndex = sm.indexOfItemWithTarget(applicationDelegate, OS.sel_terminate_); + long /*int*/ quitIndex = sm.indexOfItemWithTarget(applicationDelegate, OS.sel_terminate_); if (quitIndex != -1) { NSMenuItem quitItem = sm.itemAtIndex(quitIndex); @@ -5123,7 +5123,7 @@ void applicationWillFinishLaunching (int /*long*/ id, int /*long*/ sel, int /*lo } } -static int /*long*/ applicationProc(int /*long*/ id, int /*long*/ sel) { +static long /*int*/ applicationProc(long /*int*/ id, long /*int*/ sel) { //TODO optimize getting the display Display display = getCurrent (); if (display == null) { @@ -5142,7 +5142,7 @@ static int /*long*/ applicationProc(int /*long*/ id, int /*long*/ sel) { return 0; } -static int /*long*/ applicationProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +static long /*int*/ applicationProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { //TODO optimize getting the display Display display = getCurrent (); if (display == null && id != applicationDelegate.id) { @@ -5199,7 +5199,7 @@ static int /*long*/ applicationProc(int /*long*/ id, int /*long*/ sel, int /*lon return 0; } -static int /*long*/ applicationProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +static long /*int*/ applicationProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { Display display = getCurrent(); if (display == null && id != applicationDelegate.id) { @@ -5222,7 +5222,7 @@ static int /*long*/ applicationProc(int /*long*/ id, int /*long*/ sel, int /*lon return 1; } else if (sel == OS.sel_application_openFiles_) { NSArray files = new NSArray(arg1); - int /*long*/ count = files.count(); + long /*int*/ count = files.count(); for (int i=0; i<count; i++) { String file = new NSString(files.objectAtIndex(i)).getString(); Event event = new Event(); @@ -5236,7 +5236,7 @@ static int /*long*/ applicationProc(int /*long*/ id, int /*long*/ sel, int /*lon return 0; } -static int /*long*/ applicationProc(int /*long*/ id, int /*long*/sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2, int /*long*/ arg3) { +static long /*int*/ applicationProc(long /*int*/ id, long /*int*/sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) { //TODO optimize getting the display Display display = getCurrent (); if (display == null && id != applicationDelegate.id) { @@ -5251,8 +5251,8 @@ static int /*long*/ applicationProc(int /*long*/ id, int /*long*/sel, int /*long return 0; } -static int /*long*/ dialogProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { - int /*long*/ [] jniRef = new int /*long*/ [1]; +static long /*int*/ dialogProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { + long /*int*/ [] jniRef = new long /*int*/ [1]; OS.object_getInstanceVariable(id, SWT_OBJECT, jniRef); if (jniRef[0] == 0) return 0; if (sel == OS.sel_changeColor_) { @@ -5282,8 +5282,8 @@ static int /*long*/ dialogProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a return 0; } -static int /*long*/ dialogProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { - int /*long*/ [] jniRef = new int /*long*/ [1]; +static long /*int*/ dialogProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { + long /*int*/ [] jniRef = new long /*int*/ [1]; OS.object_getInstanceVariable(id, SWT_OBJECT, jniRef); if (jniRef[0] == 0) return 0; if (sel == OS.sel_panel_shouldShowFilename_) { @@ -5300,8 +5300,8 @@ static int /*long*/ dialogProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a return 0; } -static int /*long*/ dialogProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2) { - int /*long*/ [] jniRef = new int /*long*/ [1]; +static long /*int*/ dialogProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) { + long /*int*/ [] jniRef = new long /*int*/ [1]; OS.object_getInstanceVariable(id, SWT_OBJECT, jniRef); if (jniRef[0] == 0) return 0; if (sel == OS.sel_panelDidEnd_returnCode_contextInfo_) { @@ -5312,7 +5312,7 @@ static int /*long*/ dialogProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a return 0; } -static Widget LookupWidget (int /*long*/ id, int /*long*/ sel) { +static Widget LookupWidget (long /*int*/ id, long /*int*/ sel) { Widget widget = GetWidget(id); if (widget == null) { NSView view = new NSView (id); @@ -5325,10 +5325,10 @@ static Widget LookupWidget (int /*long*/ id, int /*long*/ sel) { return widget; } -static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel) { +static long /*int*/ windowProc(long /*int*/ id, long /*int*/ sel) { if (sel == OS.sel_cellClass) { - int /*long*/ superCls = OS.objc_msgSend(OS.class_getSuperclass(id), sel); - int /*long*/ cls = OS.objc_lookUpClass("SWTAccessible" + OS.class_getName(superCls)); + long /*int*/ superCls = OS.objc_msgSend(OS.class_getSuperclass(id), sel); + long /*int*/ cls = OS.objc_lookUpClass("SWTAccessible" + OS.class_getName(superCls)); return cls != 0 ? cls : superCls; } /* @@ -5382,19 +5382,19 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel) { } else if (sel == OS.sel_markedRange) { NSRange range = widget.markedRange (id, sel); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRange.sizeof); + long /*int*/ result = OS.malloc (NSRange.sizeof); OS.memmove (result, range, NSRange.sizeof); return result; } else if (sel == OS.sel_selectedRange) { NSRange range = widget.selectedRange (id, sel); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRange.sizeof); + long /*int*/ result = OS.malloc (NSRange.sizeof); OS.memmove (result, range, NSRange.sizeof); return result; } else if (sel == OS.sel_cellSize) { NSSize size = widget.cellSize (id, sel); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSSize.sizeof); + long /*int*/ result = OS.malloc (NSSize.sizeof); OS.memmove (result, size, NSSize.sizeof); return result; } else if (sel == OS.sel_hasMarkedText) { @@ -5435,7 +5435,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel) { return 0; } -static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +static long /*int*/ windowProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { /* * Feature in Cocoa. In Cocoa, the default button animation is done * in a separate thread that calls drawRect() and isOpaque() from @@ -5588,7 +5588,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a } else if (sel == OS.sel_firstRectForCharacterRange_) { NSRect rect = widget.firstRectForCharacterRange (id, sel, arg0); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRect.sizeof); + long /*int*/ result = OS.malloc (NSRect.sizeof); OS.memmove (result, rect, NSRect.sizeof); return result; } else if (sel == OS.sel_insertText_) { @@ -5630,7 +5630,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a } else if (sel == OS.sel_headerRectOfColumn_) { NSRect rect = widget.headerRectOfColumn(id, sel, arg0); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRect.sizeof); + long /*int*/ result = OS.malloc (NSRect.sizeof); OS.memmove (result, rect, NSRect.sizeof); return result; } else if (sel == OS.sel_imageRectForBounds_) { @@ -5638,7 +5638,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a OS.memmove(rect, arg0, NSRect.sizeof); rect = widget.imageRectForBounds(id, sel, rect); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRect.sizeof); + long /*int*/ result = OS.malloc (NSRect.sizeof); OS.memmove (result, rect, NSRect.sizeof); return result; } else if (sel == OS.sel_titleRectForBounds_) { @@ -5646,7 +5646,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a OS.memmove(rect, arg0, NSRect.sizeof); rect = widget.titleRectForBounds(id, sel, rect); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRect.sizeof); + long /*int*/ result = OS.malloc (NSRect.sizeof); OS.memmove (result, rect, NSRect.sizeof); return result; } else if (sel == OS.sel_cellSizeForBounds_) { @@ -5654,7 +5654,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a OS.memmove(rect, arg0, NSRect.sizeof); NSSize size = widget.cellSizeForBounds(id, sel, rect); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSSize.sizeof); + long /*int*/ result = OS.malloc (NSSize.sizeof); OS.memmove (result, size, NSSize.sizeof); return result; } else if (sel == OS.sel_setObjectValue_) { @@ -5664,7 +5664,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a } else if (sel == OS.sel_sizeOfLabel_) { NSSize size = widget.sizeOfLabel(id, sel, arg0 != 0); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc(NSSize.sizeof); + long /*int*/ result = OS.malloc(NSSize.sizeof); OS.memmove(result, size, NSSize.sizeof); return result; } else if (sel == OS.sel_comboBoxSelectionDidChange_) { @@ -5729,7 +5729,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a return 0; } -static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +static long /*int*/ windowProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { Widget widget = LookupWidget(id, sel); if (widget == null) return 0; if (sel == OS.sel_tabView_willSelectTabViewItem_) { @@ -5773,7 +5773,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a OS.memmove(rect, arg0, NSRect.sizeof); rect = widget.expansionFrameWithFrame_inView(id, sel, rect, arg1); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRect.sizeof); + long /*int*/ result = OS.malloc (NSRect.sizeof); OS.memmove (result, rect, NSRect.sizeof); return result; } else if (sel == OS.sel_drawLabel_inRect_) { @@ -5798,7 +5798,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a return 0; } -static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2) { +static long /*int*/ windowProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) { Widget widget = LookupWidget(id, sel); if (widget == null) return 0; if (sel == OS.sel_tableView_objectValueForTableColumn_row_) { @@ -5820,7 +5820,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a } else if (sel == OS.sel_textView_willChangeSelectionFromCharacterRange_toCharacterRange_) { NSRange range = widget.textView_willChangeSelectionFromCharacterRange_toCharacterRange(id, sel, arg0, arg1, arg2); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRange.sizeof); + long /*int*/ result = OS.malloc (NSRange.sizeof); OS.memmove (result, range, NSRange.sizeof); return result; } else if (sel == OS.sel_dragSelectionWithEvent_offset_slideBack_) { @@ -5836,7 +5836,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a OS.memmove (rect, arg1, NSRect.sizeof); rect = widget.drawTitleWithFrameInView (id, sel, arg0, rect, arg2); /* NOTE that this is freed in C */ - int /*long*/ result = OS.malloc (NSRect.sizeof); + long /*int*/ result = OS.malloc (NSRect.sizeof); OS.memmove (result, rect, NSRect.sizeof); return result; } else if (sel == OS.sel_hitTestForEvent_inRect_ofView_) { @@ -5853,7 +5853,7 @@ static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ a return 0; } -static int /*long*/ windowProc(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2, int /*long*/ arg3) { +static long /*int*/ windowProc(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) { Widget widget = LookupWidget(id, sel); if (widget == null) return 0; if (sel == OS.sel_tableView_willDisplayCell_forTableColumn_row_) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FileDialog.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FileDialog.java index e0be23abc7..427034f135 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FileDialog.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FileDialog.java @@ -201,15 +201,15 @@ public boolean getOverwrite () { public String open () { String fullPath = null; fileNames = new String [0]; - int /*long*/ method = 0; - int /*long*/ methodImpl = 0; + long /*int*/ method = 0; + long /*int*/ methodImpl = 0; Callback callback = null; if ((style & SWT.SAVE) != 0) { NSSavePanel savePanel = NSSavePanel.savePanel(); panel = savePanel; if (!overwrite) { callback = new Callback(this, "_overwriteExistingFileCheck", 3); - int /*long*/ proc = callback.getAddress(); + long /*int*/ proc = callback.getAddress(); if (proc == 0) error (SWT.ERROR_NO_MORE_CALLBACKS); method = OS.class_getInstanceMethod(OS.class_NSSavePanel, OS.sel_overwriteExistingFileCheck); if (method != 0) methodImpl = OS.method_setImplementation(method, proc); @@ -223,7 +223,7 @@ public String open () { Display display = parent != null ? parent.getDisplay() : Display.getCurrent(); panel.setCanCreateDirectories(true); OS.objc_msgSend(panel.id, OS.sel_setShowsHiddenFiles_, true); - int /*long*/ jniRef = 0; + long /*int*/ jniRef = 0; SWTPanelDelegate delegate = null; if (filterExtensions != null && filterExtensions.length != 0) { delegate = (SWTPanelDelegate)new SWTPanelDelegate().alloc().init(); @@ -260,7 +260,7 @@ public String open () { display.setModalDialog(this); NSString dir = (filterPath != null && filterPath.length() > 0) ? NSString.stringWith(filterPath) : null; NSString file = (fileName != null && fileName.length() > 0) ? NSString.stringWith(fileName) : null; - int /*long*/ response = panel.runModalForDirectory(dir, file); + long /*int*/ response = panel.runModalForDirectory(dir, file); if (parent != null && (style & SWT.SHEET) != 0) { application.endSheet(panel, 0); } @@ -339,15 +339,15 @@ public String open () { return fullPath; } -int /*long*/ _overwriteExistingFileCheck (int /*long*/ id, int /*long*/ sel, int /*long*/ str) { +long /*int*/ _overwriteExistingFileCheck (long /*int*/ id, long /*int*/ sel, long /*int*/ str) { return 1; } -int /*long*/ panel_shouldShowFilename (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +long /*int*/ panel_shouldShowFilename (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { NSString path = new NSString(arg1); if (filterExtensions != null && filterExtensions.length != 0) { NSFileManager manager = NSFileManager.defaultManager(); - int /*long*/ ptr = OS.malloc(1); + long /*int*/ ptr = OS.malloc(1); boolean found = manager.fileExistsAtPath(path, ptr); byte[] isDirectory = new byte[1]; OS.memmove(isDirectory, ptr, 1); @@ -376,7 +376,7 @@ int /*long*/ panel_shouldShowFilename (int /*long*/ id, int /*long*/ sel, int /* return 1; } -void sendSelection (int /*long*/ id, int /*long*/ sel, int /*long*/ arg) { +void sendSelection (long /*int*/ id, long /*int*/ sel, long /*int*/ arg) { panel.validateVisibleColumns(); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FontDialog.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FontDialog.java index b1ec63df48..b180df08d3 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FontDialog.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/FontDialog.java @@ -85,7 +85,7 @@ public FontDialog (Shell parent, int style) { checkSubclass (); } -void changeFont(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void changeFont(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { selected = true; } @@ -165,7 +165,7 @@ public FontData open () { Font font = create ? new Font(display, fontData) : display.getSystemFont(); panel.setPanelFont(font.handle, false); SWTPanelDelegate delegate = (SWTPanelDelegate)new SWTPanelDelegate().alloc().init(); - int /*long*/ jniRef = OS.NewGlobalRef(this); + long /*int*/ jniRef = OS.NewGlobalRef(this); if (jniRef == 0) error(SWT.ERROR_NO_HANDLES); OS.object_setInstanceVariable(delegate.id, Display.SWT_OBJECT, jniRef); panel.setDelegate(delegate); @@ -188,12 +188,12 @@ public FontData open () { return fontData; } -void setColor_forAttribute(int /*long*/ id, int /*long*/ sel, int /*long*/ colorArg, int /*long*/ attribute) { +void setColor_forAttribute(long /*int*/ id, long /*int*/ sel, long /*int*/ colorArg, long /*int*/ attribute) { if (attribute != 0 && NSString.stringWith("NSColor").isEqualToString(new NSString(attribute))) { //$NON-NLS-1$ if (colorArg != 0) { NSColor color = new NSColor(colorArg); Display display = parent != null ? parent.getDisplay() : Display.getCurrent(); - float /*double*/ [] handle = display.getNSColorRGB(color); + double /*float*/ [] handle = display.getNSColorRGB(color); rgb = new RGB((int)(handle[0] * 255), (int)(handle[1] * 255), (int)(handle[2] * 255)); } else { rgb = null; @@ -264,11 +264,11 @@ public void setRGB (RGB rgb) { this.rgb = rgb; } -int validModesForFontPanel(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +int validModesForFontPanel(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { return effectsVisible ? OS.NSFontPanelAllModesMask : OS.NSFontPanelAllModesMask & ~OS.NSFontPanelAllEffectsModeMask; } -void windowWillClose(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void windowWillClose(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { NSApplication.sharedApplication().stop(null); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Group.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Group.java index 9e21ba4c92..02f2a8b812 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Group.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Group.java @@ -151,7 +151,7 @@ void deregister () { display.removeWidget (box.titleCell()); } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; fillBackground (view, context, rect, -1); } @@ -217,7 +217,7 @@ void setFont(NSFont font) { ((NSBox) view).setTitleFont(font); } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { NSColor nsColor; if (color == null) { nsColor = NSColor.textColor (); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/IME.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/IME.java index 2a8d81d805..6e04f8b9d0 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/IME.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/IME.java @@ -85,7 +85,7 @@ public IME (Canvas parent, int style) { createWidget (); } -int /*long*/ attributedSubstringFromRange (int /*long*/ id, int /*long*/ sel, int /*long*/ rangePtr) { +long /*int*/ attributedSubstringFromRange (long /*int*/ id, long /*int*/ sel, long /*int*/ rangePtr) { Event event = new Event (); event.detail = SWT.COMPOSITION_SELECTION; sendEvent (SWT.ImeComposition, event); @@ -104,7 +104,7 @@ int /*long*/ attributedSubstringFromRange (int /*long*/ id, int /*long*/ sel, in return 0; } -int /*long*/ characterIndexForPoint (int /*long*/ id, int /*long*/ sel, int /*long*/ point) { +long /*int*/ characterIndexForPoint (long /*int*/ id, long /*int*/ sel, long /*int*/ point) { if (!isInlineEnabled ()) return OS.NSNotFound; NSPoint pt = new NSPoint (); OS.memmove (pt, point, NSPoint.sizeof); @@ -128,7 +128,7 @@ void createWidget () { } } -NSRect firstRectForCharacterRange(int /*long*/ id, int /*long*/ sel, int /*long*/ range) { +NSRect firstRectForCharacterRange(long /*int*/ id, long /*int*/ sel, long /*int*/ range) { NSRect rect = new NSRect (); Caret caret = parent.caret; if (caret != null) { @@ -256,7 +256,7 @@ public TextStyle [] getStyles () { TextStyle getStyle (NSDictionary attribs) { NSArray keys = attribs.allKeys (); - int /*long*/ count = keys.count (); + long /*int*/ count = keys.count (); TextStyle style = new TextStyle (); for (int j = 0; j < count; j++) { NSString key = new NSString (keys.objectAtIndex (j)); @@ -330,11 +330,11 @@ public boolean getWideCaret() { return false; } -boolean hasMarkedText (int /*long*/ id, int /*long*/ sel) { +boolean hasMarkedText (long /*int*/ id, long /*int*/ sel) { return text.length () != 0; } -boolean insertText (int /*long*/ id, int /*long*/ sel, int /*long*/ string) { +boolean insertText (long /*int*/ id, long /*int*/ sel, long /*int*/ string) { if (startOffset == -1) return true; NSString str = new NSString (string); if (str.isKindOfClass (OS.class_NSAttributedString)) { @@ -360,7 +360,7 @@ boolean isInlineEnabled () { return hooks (SWT.ImeComposition); } -NSRange markedRange (int /*long*/ id, int /*long*/ sel) { +NSRange markedRange (long /*int*/ id, long /*int*/ sel) { NSRange range = new NSRange (); if (startOffset != -1) { range.location = startOffset; @@ -395,7 +395,7 @@ void releaseWidget () { resetStyles (); } -NSRange selectedRange (int /*long*/ id, int /*long*/ sel) { +NSRange selectedRange (long /*int*/ id, long /*int*/ sel) { Event event = new Event (); event.detail = SWT.COMPOSITION_SELECTION; sendEvent (SWT.ImeComposition, event); @@ -429,7 +429,7 @@ public void setCompositionOffset (int offset) { } } -boolean setMarkedText_selectedRange (int /*long*/ id, int /*long*/ sel, int /*long*/ string, int /*long*/ selRange) { +boolean setMarkedText_selectedRange (long /*int*/ id, long /*int*/ sel, long /*int*/ string, long /*int*/ selRange) { if (!isInlineEnabled ()) return true; resetStyles (); caretOffset = commitCount = 0; @@ -451,7 +451,7 @@ boolean setMarkedText_selectedRange (int /*long*/ id, int /*long*/ sel, int /*lo NSRange rangeLimit = new NSRange (), effectiveRange = new NSRange (); rangeLimit.length = length; int rangeCount = 0; - int /*long*/ ptr = OS.malloc (NSRange.sizeof); + long /*int*/ ptr = OS.malloc (NSRange.sizeof); for (int i = 0; i < length;) { NSDictionary attribs = attribStr.attributesAtIndex(i, ptr, rangeLimit); OS.memmove (effectiveRange, ptr, NSRange.sizeof); @@ -494,7 +494,7 @@ boolean setMarkedText_selectedRange (int /*long*/ id, int /*long*/ sel, int /*lo return true; } -int /*long*/ validAttributesForMarkedText (int /*long*/ id, int /*long*/ sel) { +long /*int*/ validAttributesForMarkedText (long /*int*/ id, long /*int*/ sel) { NSMutableArray attribs = NSMutableArray.arrayWithCapacity (6); attribs.addObject (new NSString (OS.NSForegroundColorAttributeName ())); attribs.addObject (new NSString (OS.NSBackgroundColorAttributeName ())); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Label.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Label.java index db3b4b135b..81ee8adb89 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Label.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Label.java @@ -95,11 +95,11 @@ public Label (Composite parent, int style) { super (parent, checkStyle (style)); } -int /*long*/ accessibleHandle() { +long /*int*/ accessibleHandle() { return eventView().id; } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { if (id == view.id) return true; return super.accessibilityIsIgnored(id, sel); } @@ -135,7 +135,7 @@ public Point computeSize (int wHint, int hHint, boolean changed) { int width = DEFAULT_WIDTH; int height = DEFAULT_HEIGHT; if ((style & SWT.SEPARATOR) != 0) { - float /*double*/ lineWidth = ((NSBox)view).borderWidth (); + double /*float*/ lineWidth = ((NSBox)view).borderWidth (); if ((style & SWT.HORIZONTAL) != 0) { height = (int)Math.ceil (lineWidth * 2); } else { @@ -197,7 +197,7 @@ void createHandle () { widget.setBoxType (OS.NSBoxCustom); widget.setContentViewMargins (new NSSize()); - float /*double*/ lineWidth = widget.borderWidth (); + double /*float*/ lineWidth = widget.borderWidth (); if ((style & SWT.HORIZONTAL) != 0) { rect.height = (int)Math.ceil (lineWidth * 2); rect.y = (DEFAULT_HEIGHT / 2) - (rect.height / 2); @@ -281,12 +281,12 @@ void deregister () { if (separator != null) display.removeWidget(separator); } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; fillBackground(view, context, rect, -1); } -int /*long*/ imageView() { +long /*int*/ imageView() { return imageView.id; }; @@ -436,7 +436,7 @@ void setFont(NSFont font) { } } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { if ((style & SWT.SEPARATOR) != 0) return; NSCell cell = new NSCell(textView.cell()); cell.setAttributedStringValue(createString()); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Link.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Link.java index 8b875fa648..3ae4bdac22 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Link.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Link.java @@ -110,7 +110,7 @@ public void addSelectionListener (SelectionListener listener) { addListener (SWT.DefaultSelection, typedListener); } -boolean textView_clickOnLink_atIndex(int /*long*/ id, int /*long*/ sel, int /*long*/ textView, int /*long*/ link, int /*long*/ charIndex) { +boolean textView_clickOnLink_atIndex(long /*int*/ id, long /*int*/ sel, long /*int*/ textView, long /*int*/ link, long /*int*/ charIndex) { NSString str = new NSString (link); Event event = new Event (); event.text = str.getString(); @@ -237,7 +237,7 @@ void deregister () { if (scrollView != null) display.removeWidget (scrollView); } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rectangle) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rectangle) { fillBackground (view, context, rectangle, -1); if (!hasFocus() || focusIndex == -1) return; int [] outMetric = new int [1]; @@ -308,13 +308,13 @@ NSRect[] getRectangles(int linkIndex) { range.length = offsets[linkIndex].y - offsets[linkIndex].x + 1; NSRange glyphRange = layoutManager.glyphRangeForCharacterRange(range, 0); - int /*long*/ rangePtr = OS.malloc(NSRange.sizeof); + long /*int*/ rangePtr = OS.malloc(NSRange.sizeof); NSRange lineRange = new NSRange(); /* compute number of lines in the link */ int numberOfLines = 0; - int /*long*/ index = glyphRange.location; - int /*long*/ glyphEndIndex = glyphRange.location + glyphRange.length; + long /*int*/ index = glyphRange.location; + long /*int*/ glyphEndIndex = glyphRange.location + glyphRange.length; while (index < glyphEndIndex) { numberOfLines++; layoutManager.lineFragmentUsedRectForGlyphAtIndex(index, rangePtr, true); @@ -364,7 +364,7 @@ public String getText () { return text; } -void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { /* * Feature in Cocoa: Link click notices are sent on mouseDown, but for some reason, Cocoa * re-sends the mouseUp that follows the click on a link. Fix is to ignore the next mouseUp @@ -377,7 +377,7 @@ void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { super.mouseUp(id, sel, theEvent); } -boolean shouldDrawInsertionPoint(int /*long*/ id, int /*long*/ sel) { +boolean shouldDrawInsertionPoint(long /*int*/ id, long /*int*/ sel) { return false; } @@ -638,7 +638,7 @@ void setFont(NSFont font) { ((NSTextView) view).setFont(font); } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { if (!getEnabled ()) return; NSColor nsColor; if (color == null) { @@ -724,7 +724,7 @@ int traversalCode (int key, NSEvent theEvent) { if (offsets.length == 0) return 0; int bits = super.traversalCode (key, theEvent); if (key == 48 /* Tab */ && theEvent != null) { - int /*long*/ modifierFlags = theEvent.modifierFlags(); + long /*int*/ modifierFlags = theEvent.modifierFlags(); boolean next = (modifierFlags & OS.NSShiftKeyMask) == 0; if (next && focusIndex < offsets.length - 1) { return bits & ~ SWT.TRAVERSE_TAB_NEXT; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/List.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/List.java index 72cd7a9bd4..dffd19de3b 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/List.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/List.java @@ -81,7 +81,7 @@ public List (Composite parent, int style) { super (parent, checkStyle (style)); } -int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityAttributeValue (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { // if (attributeName.isEqualToString(OS.NSAccessibilityHeaderAttribute)) { // /* // * Bug in the Macintosh. Even when the header is not visible, @@ -96,7 +96,7 @@ int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int return super.accessibilityAttributeValue(id, sel, arg0); } -boolean acceptsFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean acceptsFirstResponder (long /*int*/ id, long /*int*/ sel) { return true; } @@ -387,7 +387,7 @@ boolean dragDetect(int x, int y, boolean filter, boolean[] consume) { NSPoint pt = new NSPoint(); pt.x = x; pt.y = y; - int /*long*/ row = widget.rowAtPoint(pt); + long /*int*/ row = widget.rowAtPoint(pt); if (row == -1) return false; boolean dragging = super.dragDetect(x, y, filter, consume); if (dragging) { @@ -403,7 +403,7 @@ boolean dragDetect(int x, int y, boolean filter, boolean[] consume) { return dragging; } -void drawBackgroundInClipRect(int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawBackgroundInClipRect(long /*int*/ id, long /*int*/ sel, NSRect rect) { super.drawViewBackgroundInRect(id, sel, rect); if (id != view.id) return; fillBackground (view, NSGraphicsContext.currentContext(), rect, -1); @@ -544,7 +544,7 @@ public String [] getSelection () { } NSIndexSet selection = widget.selectedRowIndexes(); int count = (int)/*64*/selection.count(); - int /*long*/ [] indexBuffer = new int /*long*/ [count]; + long /*int*/ [] indexBuffer = new long /*int*/ [count]; selection.getIndexes(indexBuffer, count, 0); String [] result = new String [count]; for (int i=0; i<count; i++) { @@ -587,7 +587,7 @@ public int getSelectionIndex () { } NSIndexSet selection = widget.selectedRowIndexes(); int count = (int)/*64*/selection.count(); - int /*long*/ [] result = new int /*long*/ [count]; + long /*int*/ [] result = new long /*int*/ [count]; selection.getIndexes(result, count, 0); return (int)/*64*/result [0]; } @@ -616,7 +616,7 @@ public int [] getSelectionIndices () { } NSIndexSet selection = widget.selectedRowIndexes(); int count = (int)/*64*/selection.count(); - int /*long*/ [] indices = new int /*long*/ [count]; + long /*int*/ [] indices = new long /*int*/ [count]; selection.getIndexes(indices, count, 0); int [] result = new int [count]; for (int i = 0; i < result.length; i++) { @@ -729,7 +729,7 @@ public boolean isSelected (int index) { * right-clicks or control-clicks on an NSTableView or its subclasses. Fix is to select the * clicked-on row ourselves. */ -int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +long /*int*/ menuForEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { NSEvent event = new NSEvent(theEvent); NSTableView table = (NSTableView)view; @@ -738,7 +738,7 @@ int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEve // select the row that was clicked before showing the menu for the event NSPoint mousePoint = view.convertPoint_fromView_(event.locationInWindow(), null); - int /*long*/ row = table.rowAtPoint(mousePoint); + long /*int*/ row = table.rowAtPoint(mousePoint); // figure out if the row that was just clicked on is currently selected if (selectedRowIndexes.containsIndex(row) == false) { @@ -752,7 +752,7 @@ int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEve return super.menuForEvent(id, sel, theEvent); } -void mouseDownSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDownSuper(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { ignoreSelect = false; NSTableView widget = (NSTableView)view; NSEvent nsEvent = new NSEvent(theEvent); @@ -770,11 +770,11 @@ void mouseDownSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { didSelect = false; } -boolean needsPanelToBecomeKey (int /*long*/ id, int /*long*/ sel) { +boolean needsPanelToBecomeKey (long /*int*/ id, long /*int*/ sel) { return false; } -int /*long*/ numberOfRowsInTableView(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView) { +long /*int*/ numberOfRowsInTableView(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView) { return itemCount; } @@ -1136,8 +1136,8 @@ void setBackgroundColor(NSColor nsColor) { void setFont (NSFont font) { super.setFont (font); - float /*double*/ ascent = font.ascender (); - float /*double*/ descent = -font.descender () + font.leading (); + double /*float*/ ascent = font.ascender (); + double /*float*/ descent = -font.descender () + font.leading (); ((NSTableView)view).setRowHeight ((int)Math.ceil (ascent + descent) + 1); setScrollWidth(); } @@ -1203,7 +1203,7 @@ boolean setScrollWidth (String item) { cell.setFont (font.handle); cell.setTitle (NSString.stringWith (item)); NSSize size = cell.cellSize (); - float /*double*/ oldWidth = column.width (); + double /*float*/ oldWidth = column.width (); if (oldWidth < size.width) { column.setWidth (size.width); return true; @@ -1217,7 +1217,7 @@ boolean setScrollWidth () { NSCell cell = column.dataCell (); Font font = this.font != null ? this.font : defaultFont (); cell.setFont (font.handle); - float /*double*/ width = 0; + double /*float*/ width = 0; for (int i = 0; i < itemCount; i++) { cell.setTitle (NSString.stringWith (items[i])); NSSize size = cell.cellSize (); @@ -1444,24 +1444,24 @@ public void showSelection () { if (index >= 0) showIndex (index); } -void tableViewSelectionDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewSelectionDidChange (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { if (didSelect) return; sendSelection(); } -void tableViewSelectionIsChanging (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewSelectionIsChanging (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { didSelect = true; sendSelection(); } -int /*long*/ tableView_objectValueForTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ aTableColumn, int /*long*/ rowIndex) { - float /*double*/ [] fg = ((NSTableView)view).isRowSelected(rowIndex) ? null : foreground; +long /*int*/ tableView_objectValueForTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ aTableColumn, long /*int*/ rowIndex) { + double /*float*/ [] fg = ((NSTableView)view).isRowSelected(rowIndex) ? null : foreground; NSAttributedString attribStr = createString(items[(int)/*64*/rowIndex], null, fg, SWT.LEFT, false, getEnabled(), false); attribStr.autorelease(); return attribStr.id; } -int /*long*/ tableView_selectionIndexesForProposedSelection (int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ indexSet) { +long /*int*/ tableView_selectionIndexesForProposedSelection (long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ indexSet) { if ((style & SWT.SINGLE) != 0) { /* * Feature in Cocoa. Calling setAllowsEmptySelection will automatically select the first row of the list. diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Menu.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Menu.java index d82395f36f..f06d34199e 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Menu.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Menu.java @@ -264,7 +264,7 @@ void _setVisible (boolean visible) { NSView topView = window.contentView(); Point shellCoord = display.map(null, shell, new Point(x,y)); location = new NSPoint (); - float /*double*/ scaleFactor = window.userSpaceScaleFactor(); + double /*float*/ scaleFactor = window.userSpaceScaleFactor(); location.x = shellCoord.x * scaleFactor; location.y = (topView.frame().height - shellCoord.y) * scaleFactor; } else { @@ -345,8 +345,8 @@ void createHandle () { nsMenu = widget; } else { nsMenu.retain(); - int /*long*/ cls = OS.object_getClass(nsMenu.id); - int /*long*/ dynNSMenu_class = display.createMenuSubclass(cls, "SWTSystemMenu", true); + long /*int*/ cls = OS.object_getClass(nsMenu.id); + long /*int*/ dynNSMenu_class = display.createMenuSubclass(cls, "SWTSystemMenu", true); if (cls != dynNSMenu_class) { OS.object_setClass(nsMenu.id, dynNSMenu_class); } @@ -371,8 +371,8 @@ void createItem (MenuItem item, int index) { } item.nsItem = nsItem; } else { - int /*long*/ cls = OS.object_getClass(nsItem.id); - int /*long*/ dynNSMenuItem_class = display.createMenuItemSubclass(cls, "SWTSystemMenuItem", true); + long /*int*/ cls = OS.object_getClass(nsItem.id); + long /*int*/ dynNSMenuItem_class = display.createMenuItemSubclass(cls, "SWTSystemMenuItem", true); if (cls != dynNSMenuItem_class) { OS.object_setClass(nsItem.id, dynNSMenuItem_class); } @@ -394,9 +394,9 @@ void createItem (MenuItem item, int index) { // Sync native key equivalent to MenuItem's accelerator. // The system menu on OS X only uses command and option, so it's // safe to just check for those two key masks. - int /*long*/ keyMask = nsItem.keyEquivalentModifierMask(); + long /*int*/ keyMask = nsItem.keyEquivalentModifierMask(); NSString keyEquivString = nsItem.keyEquivalent(); - int /*long*/ keyEquiv = 0; + long /*int*/ keyEquiv = 0; if (keyEquivString != null) { keyEquiv = keyEquivString.characterAtIndex(0); if ((keyMask & OS.NSCommandKeyMask) != 0) keyEquiv |= SWT.COMMAND; @@ -788,7 +788,7 @@ public boolean isVisible () { return getVisible (); } -void menu_willHighlightItem(int /*long*/ id, int /*long*/ sel, int /*long*/ menu, int /*long*/ itemID) { +void menu_willHighlightItem(long /*int*/ id, long /*int*/ sel, long /*int*/ menu, long /*int*/ itemID) { Widget widget = display.getWidget(itemID); if (widget instanceof MenuItem) { MenuItem item = (MenuItem)widget; @@ -796,23 +796,23 @@ void menu_willHighlightItem(int /*long*/ id, int /*long*/ sel, int /*long*/ menu } } -void menuNeedsUpdate(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuNeedsUpdate(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { //This code is intentionally commented //sendEvent (SWT.Show); } -void menuWillOpen(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuWillOpen(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { visible = true; sendEvent (SWT.Show); if (isDisposed()) return; - float /*double*/ width = 0; + double /*float*/ width = 0; NSAttributedString[] strs = new NSAttributedString[itemCount]; for (int i=0; i<itemCount; i++) { MenuItem item = items [i]; NSMenuItem nsItem = item.nsItem; strs[i] = nsItem.attributedTitle(); NSImage nsImage = nsItem.image(); - float /*double*/ w = GAP; + double /*float*/ w = GAP; if (strs[i] != null) { w += strs[i].size().width; } @@ -832,7 +832,7 @@ void menuWillOpen(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { if (length > 1) { NSMenuItem nsItem = item.nsItem; NSImage nsImage = nsItem.image(); - float /*double*/ tab = width; + double /*float*/ tab = width; if (nsImage != null) { tab -= (nsImage.size().width + GAP); } @@ -868,7 +868,7 @@ void menuWillOpen(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { } } -void menuDidClose(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuDidClose(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { sendEvent (SWT.Hide); if (isDisposed()) return; visible = false; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MenuItem.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MenuItem.java index ce62d49578..cebf941129 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MenuItem.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MenuItem.java @@ -40,7 +40,7 @@ public class MenuItem extends Item { NSMenuItem nsItem; Menu parent, menu; int accelerator; - int /*long*/ nsItemAction; + long /*int*/ nsItemAction; id nsItemTarget; /** diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MessageBox.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MessageBox.java index 2707036037..8212b725dc 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MessageBox.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/MessageBox.java @@ -206,7 +206,7 @@ public int open () { NSString message = NSString.stringWith(this.message != null ? this.message : ""); alert.setMessageText(message); int response = 0; - int /*long*/ jniRef = 0; + long /*int*/ jniRef = 0; SWTPanelDelegate delegate = null; Display display = parent != null ? parent.getDisplay() : Display.getCurrent(); if ((style & SWT.SHEET) != 0) { @@ -307,7 +307,7 @@ public int open () { return SWT.CANCEL; } -void panelDidEnd_returnCode_contextInfo(int /*long*/ id, int /*long*/ sel, int /*long*/ alert, int /*long*/ returnCode, int /*long*/ contextInfo) { +void panelDidEnd_returnCode_contextInfo(long /*int*/ id, long /*int*/ sel, long /*int*/ alert, long /*int*/ returnCode, long /*int*/ contextInfo) { this.returnCode = (int)/*64*/returnCode; NSApplication application = NSApplication.sharedApplication(); application.endSheet(new NSAlert(alert).window(), returnCode); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ProgressBar.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ProgressBar.java index 68acfb6dfd..af3f758116 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ProgressBar.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ProgressBar.java @@ -110,7 +110,7 @@ NSFont defaultNSFont () { return display.progressIndicatorFont; } -void _drawThemeProgressArea (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void _drawThemeProgressArea (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { /* * Bug in Cocoa. When the threaded animation is turned off by calling * setUsesThreadedAnimation(), _drawThemeProgressArea() attempts to @@ -128,7 +128,7 @@ void _drawThemeProgressArea (int /*long*/ id, int /*long*/ sel, int /*long*/ arg * region of the progress bar before calling super. */ if (visiblePath == null) { - int /*long*/ visibleRegion = getVisibleRegion(); + long /*int*/ visibleRegion = getVisibleRegion(); visiblePath = getPath(visibleRegion); OS.DisposeRgn(visibleRegion); } @@ -319,7 +319,7 @@ void resetVisibleRegion () { visiblePath = null; } -void viewDidMoveToWindow(int /*long*/ id, int /*long*/ sel) { +void viewDidMoveToWindow(long /*int*/ id, long /*int*/ sel) { /* * Bug in Cocoa. An indeterminate progress indicator doesn't start animating until it is in * a visible window. Workaround is to catch when the bar has been added to a window and start diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Sash.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Sash.java index b9eb76f0a4..68a37e41f6 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Sash.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Sash.java @@ -81,7 +81,7 @@ public Sash (Composite parent, int style) { sizeCursor = new Cursor (display, cursorStyle); } -int /*long*/ accessibilityAttributeNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityAttributeNames(long /*int*/ id, long /*int*/ sel) { if (accessibilityAttributes == null) { NSMutableArray ourAttributes = NSMutableArray.arrayWithCapacity(10); ourAttributes.addObject(OS.NSAccessibilityRoleAttribute); @@ -124,8 +124,8 @@ int /*long*/ accessibilityAttributeNames(int /*long*/ id, int /*long*/ sel) { return accessibilityAttributes.id; } -int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { - int /*long*/ returnValue = 0; +long /*int*/ accessibilityAttributeValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { + long /*int*/ returnValue = 0; NSString attributeName = new NSString(arg0); if (accessible != null) { @@ -155,7 +155,7 @@ int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int return NSNumber.numberWithInt(value).id; } else if (attributeName.isEqualToString (OS.NSAccessibilityMaxValueAttribute)) { NSRect parentFrame = parent.topView().frame(); - float /*double*/ maxValue = (style & SWT.VERTICAL) != 0 ? + double /*float*/ maxValue = (style & SWT.VERTICAL) != 0 ? parentFrame.width : parentFrame.height; return NSNumber.numberWithDouble(maxValue).id; @@ -198,7 +198,7 @@ int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int return super.accessibilityAttributeValue(id, sel, arg0); } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { return false; } @@ -243,7 +243,7 @@ static int checkStyle (int style) { return checkBits (style, SWT.HORIZONTAL, SWT.VERTICAL, 0, 0, 0, 0); } -boolean becomeFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean becomeFirstResponder (long /*int*/ id, long /*int*/ sel) { boolean result = super.becomeFirstResponder(id, sel); NSRect frame = view.frame(); lastX = (int)frame.x; @@ -271,7 +271,7 @@ void createHandle () { view = widget; } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; fillBackground (view, context, rect, -1); } @@ -296,7 +296,7 @@ boolean sendKeyEvent(NSEvent nsEvent, int type) { case 124: /* Right arrow */ { int xChange = 0, yChange = 0; int stepSize = PAGE_INCREMENT; - int /*long*/ modifiers = nsEvent.modifierFlags(); + long /*int*/ modifiers = nsEvent.modifierFlags(); if ((modifiers & OS.NSControlKeyMask) != 0) stepSize = INCREMENT; if ((style & SWT.VERTICAL) != 0) { if (keyCode == 126 || keyCode == 125) break; @@ -346,7 +346,7 @@ boolean sendKeyEvent(NSEvent nsEvent, int type) { return true; } -void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { //TODO use sendMouseEvent super.mouseDown(id, sel, theEvent); if (isDisposed()) return; @@ -372,12 +372,12 @@ void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { } } -boolean mouseEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent, int type) { +boolean mouseEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent, int type) { super.mouseEvent (id, sel, theEvent, type); return new NSEvent (theEvent).type () != OS.NSLeftMouseDown; } -void mouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { //TODO use sendMouseEvent super.mouseDragged(id, sel, theEvent); if (isDisposed()) return; @@ -408,7 +408,7 @@ void mouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { } } -void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { //TODO use sendMouseEvent super.mouseUp(id, sel, theEvent); if (isDisposed()) return; @@ -464,10 +464,10 @@ public void removeSelectionListener(SelectionListener listener) { eventTable.unhook(SWT.DefaultSelection,listener); } -void superKeyDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void superKeyDown (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { } -void superKeyUp (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void superKeyUp (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { } int traversalCode (int key, NSEvent theEvent) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scale.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scale.java index 1f382541d6..830d3c23ec 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scale.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scale.java @@ -114,7 +114,7 @@ static int checkStyle (int style) { public Point computeSize (int wHint, int hHint, boolean changed) { checkWidget(); NSSlider widget = (NSSlider)view; - float /*double*/ thickness = widget.knobThickness(); + double /*float*/ thickness = widget.knobThickness(); int width = DEFAULT_WIDTH, height = DEFAULT_HEIGHT; if ((style & SWT.HORIZONTAL) != 0) { height = (int)Math.ceil(thickness); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ScrollBar.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ScrollBar.java index 615e6b72f6..97b812f494 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ScrollBar.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ScrollBar.java @@ -89,7 +89,7 @@ public class ScrollBar extends Widget { int increment = 1; int pageIncrement = 10; id target; - int /*long*/ actionSelector; + long /*int*/ actionSelector; ScrollBar () { /* Do nothing */ @@ -730,7 +730,7 @@ void updateBar (int selection, int minimum, int maximum, int thumb) { float fraction = range <= 0 ? 1 : (float) (selection - minimum) / range; float knob = range <= 0 ? 1 : (float) thumb / (maximum - minimum); double oldFraction = widget.doubleValue(); - float /*double*/ oldKnob = widget.knobProportion(); + double /*float*/ oldKnob = widget.knobProportion(); widget.setDoubleValue(fraction); widget.setKnobProportion(knob); widget.setEnabled (range > 0); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java index 321b05ce86..b9a772f9dc 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java @@ -134,7 +134,7 @@ ScrollBar createScrollBar (int style) { bar.style = style; bar.display = display; NSScroller scroller; - int /*long*/ actionSelector; + long /*int*/ actionSelector; NSRect rect = new NSRect(); if ((style & SWT.H_SCROLL) != 0) { rect.width = 1; @@ -271,7 +271,7 @@ boolean hooksKeys () { return hooks (SWT.KeyDown) || hooks (SWT.KeyUp) || hooks (SWT.Traverse); } -boolean isEventView (int /*long*/ id) { +boolean isEventView (long /*int*/ id) { return id == eventView ().id; } @@ -331,7 +331,7 @@ void reskinChildren (int flags) { super.reskinChildren (flags); } -void scrollClipViewToPoint (int /*long*/ id, int /*long*/ sel, int /*long*/ clipView, NSPoint point) { +void scrollClipViewToPoint (long /*int*/ id, long /*int*/ sel, long /*int*/ clipView, NSPoint point) { if ((state & CANVAS) == 0 && scrollView != null) { NSClipView clip = new NSClipView (clipView); boolean oldCopies = clip.copiesOnScroll (), copies = oldCopies; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java index ef4b26e7cb..b89d822113 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java @@ -120,9 +120,9 @@ import org.eclipse.swt.internal.cocoa.*; public class Shell extends Decorations { NSWindow window; SWTWindowDelegate windowDelegate; - int /*long*/ hostWindowClass; + long /*int*/ hostWindowClass; NSWindow hostWindow; - int /*long*/ tooltipOwner, tooltipTag, tooltipUserData; + long /*int*/ tooltipOwner, tooltipTag, tooltipUserData; int glContextCount; boolean opened, moved, resized, fullScreen, center, deferFlushing, scrolling, isPopup; Control lastActive; @@ -264,7 +264,7 @@ public Shell (Display display, int style) { this (display, null, style, 0, false); } -Shell (Display display, Shell parent, int style, int /*long*/handle, boolean embedded) { +Shell (Display display, Shell parent, int style, long /*int*/handle, boolean embedded) { super (); checkSubclass (); if (display == null) display = Display.getCurrent (); @@ -390,7 +390,7 @@ public Shell (Shell parent, int style) { * * @since 3.3 */ -public static Shell internal_new (Display display, int /*long*/ handle) { +public static Shell internal_new (Display display, long /*int*/ handle) { return new Shell (display, null, SWT.NO_TRIM, handle, false); } @@ -414,7 +414,7 @@ public static Shell internal_new (Display display, int /*long*/ handle) { * * @since 3.5 */ -public static Shell cocoa_new (Display display, int /*long*/ handle) { +public static Shell cocoa_new (Display display, long /*int*/ handle) { return new Shell (display, null, SWT.NO_TRIM, handle, true); } @@ -444,7 +444,7 @@ static int checkStyle (Shell parent, int style) { return bits; } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { // The content view of a shell is always ignored. if (id == view.id) return true; return super.accessibilityIsIgnored(id, sel); @@ -482,12 +482,12 @@ public void addShellListener(ShellListener listener) { void attachObserversToWindow(NSWindow newWindow) { if (newWindow == null || newWindow.id == 0) return; - int /*long*/ newHostWindowClass = OS.object_getClass(newWindow.id); - int /*long*/ sendEventImpl = OS.class_getMethodImplementation(newHostWindowClass, OS.sel_sendEvent_); + long /*int*/ newHostWindowClass = OS.object_getClass(newWindow.id); + long /*int*/ sendEventImpl = OS.class_getMethodImplementation(newHostWindowClass, OS.sel_sendEvent_); if (sendEventImpl == Display.windowCallback3.getAddress()) return; hostWindow = newWindow; hostWindow.retain(); - int /*long*/ embeddedSubclass = display.createWindowSubclass(newHostWindowClass, "SWTAWTWindow", true); + long /*int*/ embeddedSubclass = display.createWindowSubclass(newHostWindowClass, "SWTAWTWindow", true); OS.object_setClass(hostWindow.id, embeddedSubclass); display.addWidget (hostWindow, this); hostWindowClass = newHostWindowClass; @@ -512,7 +512,7 @@ void attachObserversToWindow(NSWindow newWindow) { defaultCenter.addObserver(windowDelegate, OS.sel_windowWillClose_, OS.NSWindowWillCloseNotification, hostWindow); } -void becomeKeyWindow (int /*long*/ id, int /*long*/ sel) { +void becomeKeyWindow (long /*int*/ id, long /*int*/ sel) { Shell modal = getModalShell(); if (modal != null && modal.window != null) { modal.window.makeKeyAndOrderFront(null); @@ -534,7 +534,7 @@ void bringToTop (boolean force) { } } -boolean canBecomeKeyWindow (int /*long*/ id, int /*long*/ sel) { +boolean canBecomeKeyWindow (long /*int*/ id, long /*int*/ sel) { if (isPopup) return false; // Only answer if SWT created the window. if (window != null) { @@ -548,7 +548,7 @@ boolean canBecomeKeyWindow (int /*long*/ id, int /*long*/ sel) { } } } - int /*long*/ styleMask = window.styleMask(); + long /*int*/ styleMask = window.styleMask(); if (styleMask == OS.NSBorderlessWindowMask || (styleMask & (OS.NSNonactivatingPanelMask | OS.NSDocModalWindowMask | OS.NSResizableWindowMask)) != 0) return true; } return super.canBecomeKeyWindow (id, sel); @@ -578,7 +578,7 @@ void center () { setLocation (x, y); } -void clearDeferFlushing (int /*long*/ id, int /*long*/ sel) { +void clearDeferFlushing (long /*int*/ id, long /*int*/ sel) { deferFlushing = false; scrolling = false; if (window != null) window.flushWindowIfNeeded(); @@ -632,7 +632,7 @@ public Rectangle computeTrim (int x, int y, int width, int height) { rect.height = trim.height; if (window != null) { if (!_getFullScreen() && !fixResize()) { - float /*double*/ h = rect.height; + double /*float*/ h = rect.height; rect = window.frameRectForContentRect(rect); rect.y += h-rect.height; } @@ -692,7 +692,7 @@ void createHandle () { } display.cascadeWindow(window, screen); NSRect screenFrame = screen.frame(); - float /*double*/ width = screenFrame.width * 5 / 8, height = screenFrame.height * 5 / 8;; + double /*float*/ width = screenFrame.width * 5 / 8, height = screenFrame.height * 5 / 8;; NSRect frame = window.frame(); NSRect primaryFrame = primaryScreen.frame(); frame.y = primaryFrame.height - ((primaryFrame.height - (frame.y + frame.height)) + height); @@ -806,7 +806,7 @@ void destroyWidget () { } } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; if (regionPath != null && background == null) { context.saveGraphicsState(); @@ -905,9 +905,9 @@ public Rectangle getBounds () { checkWidget(); if (window != null) { NSRect frame = window.frame(); - float /*double*/ y = display.getPrimaryFrame().height - (int)(frame.y + frame.height); + double /*float*/ y = display.getPrimaryFrame().height - (int)(frame.y + frame.height); Rectangle rectangle = new Rectangle ((int)frame.x, (int)y, (int)frame.width, (int)frame.height); - float /*double*/ scaleFactor = view.window().userSpaceScaleFactor(); + double /*float*/ scaleFactor = view.window().userSpaceScaleFactor(); rectangle.x /= scaleFactor; rectangle.y /= scaleFactor; rectangle.width /= scaleFactor; @@ -935,7 +935,7 @@ public Rectangle getClientArea () { if (!fixResize ()) { rect = window.contentView().frame(); } else { - float /*double*/ scaleFactor = window.userSpaceScaleFactor(); + double /*float*/ scaleFactor = window.userSpaceScaleFactor(); rect = window.frame(); rect.width /= scaleFactor; rect.height /= scaleFactor; @@ -1008,9 +1008,9 @@ public Point getLocation () { if (window != null) { NSRect frame = window.frame(); - float /*double*/ y = display.getPrimaryFrame().height - (int)(frame.y + frame.height); + double /*float*/ y = display.getPrimaryFrame().height - (int)(frame.y + frame.height); Point point = new Point ((int)frame.x, (int)y); - float /*double*/ scaleFactor = view.window().userSpaceScaleFactor(); + double /*float*/ scaleFactor = view.window().userSpaceScaleFactor(); point.x /= scaleFactor; point.y /= scaleFactor; return point; @@ -1024,7 +1024,7 @@ public Point getLocation () { pt = view.convertPoint_toView_(pt, null); pt = view.window().convertBaseToScreen(pt); pt.y = primaryFrame.height - pt.y; - float /*double*/ scaleFactor = view.window().userSpaceScaleFactor(); + double /*float*/ scaleFactor = view.window().userSpaceScaleFactor(); pt.x /= scaleFactor; pt.y /= scaleFactor; return new Point((int)pt.x, (int)pt.y); @@ -1176,7 +1176,7 @@ public Point getSize () { checkWidget(); NSRect frame = (window != null ? window.frame() : view.frame()); Point point = new Point ((int) frame.width, (int) frame.height); - float /*double*/ scaleFactor = view.window().userSpaceScaleFactor(); + double /*float*/ scaleFactor = view.window().userSpaceScaleFactor(); point.x /= scaleFactor; point.y /= scaleFactor; return point; @@ -1218,7 +1218,7 @@ boolean hasRegion () { return region != null; } -void helpRequested(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void helpRequested(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { Control control = display.getFocusControl(); while (control != null) { if (control.hooks (SWT.Help)) { @@ -1261,7 +1261,7 @@ public boolean isVisible () { return getVisible (); } -boolean makeFirstResponder (int /*long*/ id, int /*long*/ sel, int /*long*/ responder) { +boolean makeFirstResponder (long /*int*/ id, long /*int*/ sel, long /*int*/ responder) { Display display = this.display; boolean result = super.makeFirstResponder(id, sel, responder); if (!display.isDisposed()) display.checkFocus(); @@ -1285,7 +1285,7 @@ void makeKeyAndOrderFront() { window.makeKeyAndOrderFront (null); } -void mouseMoved(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseMoved(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { super.mouseMoved(id, sel, theEvent); /** @@ -1300,7 +1300,7 @@ void mouseMoved(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { } } -void noResponderFor(int /*long*/ id, int /*long*/ sel, int /*long*/ selector) { +void noResponderFor(long /*int*/ id, long /*int*/ sel, long /*int*/ selector) { /** * Feature in Cocoa. If the selector is keyDown and nothing has handled the event * a system beep is generated. There's no need to beep, as many keystrokes in the SWT @@ -1490,7 +1490,7 @@ void sendToolTipEvent (boolean enter) { if (userInfo != null) { tooltipUserData = userInfo.id; } else { - int /*long*/ [] value = new int /*long*/ [1]; + long /*int*/ [] value = new long /*int*/ [1]; OS.object_getInstanceVariable(tooltipTag, new byte[]{'_','u', 's', 'e', 'r', 'I', 'n', 'f', 'o'}, value); tooltipUserData = value[0]; } @@ -1607,7 +1607,7 @@ void setBounds (int x, int y, int width, int height, boolean move, boolean resiz boolean sheet = window.isSheet(); if (sheet && move && !resize) return; int screenHeight = (int) display.getPrimaryFrame().height; - float /*double*/ scaleFactor = window.userSpaceScaleFactor(); + double /*float*/ scaleFactor = window.userSpaceScaleFactor(); x *= scaleFactor; y *= scaleFactor; width *= scaleFactor; @@ -1709,7 +1709,7 @@ public void setFullScreen (boolean fullScreen) { fullScreenFrame = NSScreen.mainScreen().frame(); if (getMonitor().equals(display.getPrimaryMonitor ())) { if (menuBar != null) { - float /*double*/ menuBarHt = NSStatusBar.systemStatusBar().thickness(); + double /*float*/ menuBarHt = NSStatusBar.systemStatusBar().thickness(); fullScreenFrame.height -= menuBarHt; OS.SetSystemUIMode(OS.kUIModeContentHidden, 0); } @@ -2023,7 +2023,7 @@ void setZOrder () { if (fixResize ()) { NSRect rect = window.frame(); rect.x = rect.y = 0; - float /*double*/ scaleFactor = window.userSpaceScaleFactor(); + double /*float*/ scaleFactor = window.userSpaceScaleFactor(); rect.width /= scaleFactor; rect.height /= scaleFactor; window.contentView().setFrame(rect); @@ -2112,7 +2112,7 @@ void updateSystemUIMode () { if (fullScreen) window.setFrame(fullScreenFrame, true); } -int /*long*/ view_stringForToolTip_point_userData (int /*long*/ id, int /*long*/ sel, int /*long*/ view, int /*long*/ tag, int /*long*/ point, int /*long*/ userData) { +long /*int*/ view_stringForToolTip_point_userData (long /*int*/ id, long /*int*/ sel, long /*int*/ view, long /*int*/ tag, long /*int*/ point, long /*int*/ userData) { NSPoint pt = new NSPoint(); OS.memmove (pt, point, NSPoint.sizeof); Control control = display.findControl (false); @@ -2126,9 +2126,9 @@ int /*long*/ view_stringForToolTip_point_userData (int /*long*/ id, int /*long*/ return NSString.stringWithCharacters (chars, length).id; } -void viewWillMoveToWindow(int /*long*/ id, int /*long*/ sel, int /*long*/ newWindow) { +void viewWillMoveToWindow(long /*int*/ id, long /*int*/ sel, long /*int*/ newWindow) { if (window == null) { - int /*long*/ currentWindow = hostWindow != null ? hostWindow.id : 0; + long /*int*/ currentWindow = hostWindow != null ? hostWindow.id : 0; if (currentWindow != 0) { removeObserversFromWindow(); } @@ -2138,7 +2138,7 @@ void viewWillMoveToWindow(int /*long*/ id, int /*long*/ sel, int /*long*/ newWin } } -void windowDidBecomeKey(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidBecomeKey(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { if (window != null) { Display display = this.display; display.setMenuBar (menuBar); @@ -2163,22 +2163,22 @@ void windowDidBecomeKey(int /*long*/ id, int /*long*/ sel, int /*long*/ notifica } } -void windowDidDeminiturize(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidDeminiturize(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { minimized = false; sendEvent(SWT.Deiconify); } -void windowDidMiniturize(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidMiniturize(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { minimized = true; sendEvent(SWT.Iconify); } -void windowDidMove(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidMove(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { moved = true; sendEvent(SWT.Move); } -void windowDidResize(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidResize(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { if (((window.collectionBehavior() & OS.NSWindowCollectionBehaviorFullScreenPrimary) == 0) && fullScreen) { window.setFrame(fullScreenFrame, true); NSRect contentViewFrame = new NSRect(); @@ -2189,7 +2189,7 @@ void windowDidResize(int /*long*/ id, int /*long*/ sel, int /*long*/ notificatio if (fixResize ()) { NSRect rect = window.frame (); rect.x = rect.y = 0; - float /*double*/ scaleFactor = window.userSpaceScaleFactor(); + double /*float*/ scaleFactor = window.userSpaceScaleFactor(); rect.width /= scaleFactor; rect.height /= scaleFactor; window.contentView ().setFrame (rect); @@ -2203,7 +2203,7 @@ void windowDidResize(int /*long*/ id, int /*long*/ sel, int /*long*/ notificatio } } -void windowDidResignKey(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidResignKey(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { if (display.isDisposed()) return; sendEvent (SWT.Deactivate); if (isDisposed ()) return; @@ -2212,7 +2212,7 @@ void windowDidResignKey(int /*long*/ id, int /*long*/ sel, int /*long*/ notifica saveFocus(); } -void windowSendEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void windowSendEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { NSEvent nsEvent = new NSEvent (event); int type = (int)/*64*/nsEvent.type (); switch (type) { @@ -2307,12 +2307,12 @@ void windowSendEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { super.windowSendEvent (id, sel, event); } -boolean windowShouldClose(int /*long*/ id, int /*long*/ sel, int /*long*/ window) { +boolean windowShouldClose(long /*int*/ id, long /*int*/ sel, long /*int*/ window) { if (isEnabled()) closeWidget (false); return false; } -void windowWillClose(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowWillClose(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { closeWidget(true); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Spinner.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Spinner.java index 260b8dcb90..e2c0710c72 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Spinner.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Spinner.java @@ -99,12 +99,12 @@ public Spinner (Composite parent, int style) { super (parent, checkStyle (style)); } -boolean acceptsFirstResponder(int /*long*/ id, int /*long*/ sel) { +boolean acceptsFirstResponder(long /*int*/ id, long /*int*/ sel) { if (id == view.id) return false; return super.acceptsFirstResponder (id, sel); } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { if (id == view.id) return true; return super.accessibilityIsIgnored(id, sel); } @@ -210,7 +210,7 @@ protected void checkSubclass () { public Point computeSize (int wHint, int hHint, boolean changed) { checkWidget (); - float /*double*/ width = 0, height = 0; + double /*float*/ width = 0, height = 0; String string = Double.toString (buttonView.maxValue ()); Font font = Font.cocoa_new(display, textView.font ()); NSAttributedString str = parent.createString(string, font, null, 0, false, true, false); @@ -335,7 +335,7 @@ void deregister () { } } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (backgroundImage == null) return; if (new NSView(id).isKindOfClass(OS.class_NSText)) { NSText text = new NSText(id); @@ -538,13 +538,13 @@ public int getTextLimit () { return textLimit; } -boolean handleIsAccessible(int /*long*/ id) { +boolean handleIsAccessible(long /*int*/ id) { // All subviews of a Spinner can have their accessible properties overridden. // The top-level NSView is already ignored, so we don't need to test for that. return true; } -boolean isEventView (int /*long*/ id) { +boolean isEventView (long /*int*/ id) { return true; } @@ -784,7 +784,7 @@ void setFont(NSFont font) { textView.setFont(font); } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { NSColor nsColor; if (color == null) { nsColor = NSColor.textColor (); @@ -1010,14 +1010,14 @@ public void setValues (int selection, int minimum, int maximum, int digits, int setSelection (selection, true, true, false); } -boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ sel, int /*long*/ affectedCharRange, int /*long*/ replacementString) { +boolean shouldChangeTextInRange_replacementString(long /*int*/ id, long /*int*/ sel, long /*int*/ affectedCharRange, long /*int*/ replacementString) { NSRange range = new NSRange(); OS.memmove(range, affectedCharRange, NSRange.sizeof); boolean result = callSuperBoolean(id, sel, range, replacementString); if (hooks (SWT.Verify)) { String text = new NSString(replacementString).getString(); NSEvent currentEvent = display.application.currentEvent(); - int /*long*/ type = currentEvent.type(); + long /*int*/ type = currentEvent.type(); if (type != OS.NSKeyDown && type != OS.NSKeyUp) currentEvent = null; String newText = verifyText(text, (int)/*64*/range.location, (int)/*64*/(range.location+range.length), currentEvent); if (newText == null) return false; @@ -1027,7 +1027,7 @@ boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ if (fieldEditor != null) { NSRange selectedRange = fieldEditor.selectedRange(); if (textLimit != LIMIT) { - int /*long*/ charCount = fieldEditor.string().length(); + long /*int*/ charCount = fieldEditor.string().length(); if (charCount - selectedRange.length + length > textLimit) { length = (int)/*64*/(textLimit - charCount + selectedRange.length); } @@ -1044,7 +1044,7 @@ boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ return result; } -void textDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textDidChange (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { super.textDidChange (id, sel, aNotification); boolean [] parseFail = new boolean [1]; int value = getSelectionText (parseFail); @@ -1057,14 +1057,14 @@ void textDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotificatio postEvent (SWT.Modify); } -NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange (int /*long*/ id, int /*long*/ sel, int /*long*/ aTextView, int /*long*/ oldSelectedCharRange, int /*long*/ newSelectedCharRange) { +NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange (long /*int*/ id, long /*int*/ sel, long /*int*/ aTextView, long /*int*/ oldSelectedCharRange, long /*int*/ newSelectedCharRange) { /* allow the selection change to proceed */ NSRange result = new NSRange (); OS.memmove(result, newSelectedCharRange, NSRange.sizeof); return result; } -void textDidEndEditing(int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textDidEndEditing(long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { boolean [] parseFail = new boolean [1]; int value = getSelectionText (parseFail); if (parseFail [0]) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabFolder.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabFolder.java index a8f0efd89b..e32466a985 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabFolder.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabFolder.java @@ -211,7 +211,7 @@ void destroyItem (TabItem item) { ((NSTabView)view).removeTabViewItem(item.nsItem); } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; fillBackground (view, context, rect, -1); } @@ -502,7 +502,7 @@ void setFont (NSFont font) { } } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { super.setForeground(color); int index = getSelectionIndex(); for (int i = 0; i < itemCount; i++) { @@ -632,7 +632,7 @@ boolean traversePage (boolean next) { return index == getSelectionIndex (); } -void tabView_willSelectTabViewItem(int /*long*/ id, int /*long*/ sel, int /*long*/ tabView, int /*long*/ tabViewItem) { +void tabView_willSelectTabViewItem(long /*int*/ id, long /*int*/ sel, long /*int*/ tabView, long /*int*/ tabViewItem) { if (tabViewItem == 0) return; for (int i = 0; i < itemCount; i++) { TabItem item = items [i]; @@ -658,7 +658,7 @@ void tabView_willSelectTabViewItem(int /*long*/ id, int /*long*/ sel, int /*long } } -void tabView_didSelectTabViewItem(int /*long*/ id, int /*long*/ sel, int /*long*/ tabView, int /*long*/ tabViewItem) { +void tabView_didSelectTabViewItem(long /*int*/ id, long /*int*/ sel, long /*int*/ tabView, long /*int*/ tabViewItem) { if (tabViewItem == 0) return; for (int i = 0; i < itemCount; i++) { TabItem item = items [i]; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabItem.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabItem.java index 50ede9aa3c..eecc929492 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabItem.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TabItem.java @@ -114,7 +114,7 @@ public TabItem (TabFolder parent, int style, int index) { parent.createItem (this, index); } -int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityAttributeValue (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { if (id == nsItem.id) { NSString nsAttributeName = new NSString(arg0); @@ -147,7 +147,7 @@ void destroyWidget () { releaseHandle (); } -void drawLabelInRect(int /*long*/ id, int /*long*/ sel, boolean shouldTruncateLabel, NSRect rect) { +void drawLabelInRect(long /*int*/ id, long /*int*/ sel, boolean shouldTruncateLabel, NSRect rect) { if (image != null && !image.isDisposed()) { NSSize imageSize = image.handle.size(); NSRect destRect = new NSRect(); @@ -188,8 +188,8 @@ public Rectangle getBounds() { checkWidget(); Rectangle result = new Rectangle (0, 0, 0, 0); if (nsItem.respondsToSelector (OS.sel_accessibilityAttributeValue_)) { - int /*long*/ posValue = OS.objc_msgSend (nsItem.id, OS.sel_accessibilityAttributeValue_, OS.NSAccessibilityPositionAttribute ()); - int /*long*/ sizeValue = OS.objc_msgSend (nsItem.id, OS.sel_accessibilityAttributeValue_, OS.NSAccessibilitySizeAttribute ()); + long /*int*/ posValue = OS.objc_msgSend (nsItem.id, OS.sel_accessibilityAttributeValue_, OS.NSAccessibilityPositionAttribute ()); + long /*int*/ sizeValue = OS.objc_msgSend (nsItem.id, OS.sel_accessibilityAttributeValue_, OS.NSAccessibilitySizeAttribute ()); NSValue val = new NSValue (posValue); NSPoint pt = val.pointValue (); NSWindow window = parent.view.window (); @@ -416,7 +416,7 @@ public void setToolTipText (String string) { parent.checkToolTip (this); } -NSSize sizeOfLabel(int /*long*/ id, int /*long*/ sel, boolean shouldTruncateLabel) { +NSSize sizeOfLabel(long /*int*/ id, long /*int*/ sel, boolean shouldTruncateLabel) { NSSize size = super.sizeOfLabel(id, sel, shouldTruncateLabel); if (image != null && !image.isDisposed()) { NSSize imageSize = image.handle.size(); @@ -442,7 +442,7 @@ void updateText (boolean selected) { if (attriStr != null) { attriStr.release(); } - float /*double*/ [] foreground = parent.foreground; + double /*float*/ [] foreground = parent.foreground; if (foreground == null && selected && OS.VERSION >= 0x1070) { foreground = display.getNSColorRGB(NSColor.alternateSelectedControlTextColor()); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Table.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Table.java index 8b9832b9c9..7c4fc136c6 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Table.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Table.java @@ -126,19 +126,19 @@ public Table (Composite parent, int style) { super (parent, checkStyle (style)); } -boolean acceptsFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean acceptsFirstResponder (long /*int*/ id, long /*int*/ sel) { return true; } -int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { - int /*long*/ returnValue = 0; +long /*int*/ accessibilityAttributeValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { + long /*int*/ returnValue = 0; NSString attributeName = new NSString(arg0); // If the check column is visible, don't report it back as a column for accessibility purposes. // The check column is meant to appear as a part of the first column. if (attributeName.isEqualToString (OS.NSAccessibilityColumnsAttribute) || attributeName.isEqualToString(OS.NSAccessibilityVisibleColumnsAttribute)) { if ((style & SWT.CHECK) != 0) { - int /*long*/ superValue = super.accessibilityAttributeValue(id, sel, arg0); + long /*int*/ superValue = super.accessibilityAttributeValue(id, sel, arg0); if (superValue != 0) { NSArray columns = new NSArray(superValue); NSMutableArray columnsWithoutCheck = NSMutableArray.arrayWithCapacity(columns.count() - 1); @@ -213,18 +213,18 @@ int calculateWidth (TableItem[] items, int index, GC gc) { return width; } -NSSize cellSize (int /*long*/ id, int /*long*/ sel) { +NSSize cellSize (long /*int*/ id, long /*int*/ sel) { NSSize size = super.cellSize(id, sel); NSCell cell = new NSCell(id); NSImage image = cell.image(); if (image != null) size.width += imageBounds.width + IMAGE_GAP; if (hooks(SWT.MeasureItem)) { - int /*long*/ [] outValue = new int /*long*/ [1]; + long /*int*/ [] outValue = new long /*int*/ [1]; OS.object_getInstanceVariable(id, Display.SWT_ROW, outValue); - int /*long*/ rowIndex = outValue [0]; + long /*int*/ rowIndex = outValue [0]; TableItem item = _getItem((int)/*64*/rowIndex); OS.object_getInstanceVariable(id, Display.SWT_COLUMN, outValue); - int /*long*/ tableColumn = outValue[0]; + long /*int*/ tableColumn = outValue[0]; int columnIndex = 0; for (int i=0; i<columnCount; i++) { if (columns [i].nsColumn.id == tableColumn) { @@ -237,13 +237,13 @@ NSSize cellSize (int /*long*/ id, int /*long*/ sel) { return size; } -boolean canDragRowsWithIndexes_atPoint(int /*long*/ id, int /*long*/ sel, int /*long*/ rowIndexes, NSPoint mouseDownPoint) { +boolean canDragRowsWithIndexes_atPoint(long /*int*/ id, long /*int*/ sel, long /*int*/ rowIndexes, NSPoint mouseDownPoint) { if (!super.canDragRowsWithIndexes_atPoint(id, sel, rowIndexes, mouseDownPoint)) return false; // If the current row is not selected and the user is not attempting to modify the selection, select the row first. NSTableView widget = (NSTableView)view; - int /*long*/ row = widget.rowAtPoint(mouseDownPoint); - int /*long*/ modifiers = NSApplication.sharedApplication().currentEvent().modifierFlags(); + long /*int*/ row = widget.rowAtPoint(mouseDownPoint); + long /*int*/ modifiers = NSApplication.sharedApplication().currentEvent().modifierFlags(); boolean drag = (state & DRAG_DETECT) != 0 && hooks (SWT.DragDetect); if (drag) { @@ -442,7 +442,7 @@ void clearCachedWidth (TableItem[] items) { } } -int /*long*/ columnAtPoint(int /*long*/ id, int /*long*/ sel, NSPoint point) { +long /*int*/ columnAtPoint(long /*int*/ id, long /*int*/ sel, NSPoint point) { if ((style & SWT.CHECK) != 0) { if (point.x <= getCheckColumnWidth() && point.y < headerView.frame().height) return 1; } @@ -554,7 +554,7 @@ void createHandle () { widget.addTableColumn (checkColumn); checkColumn.setResizingMask(OS.NSTableColumnNoResizing); checkColumn.setEditable(false); - int /*long*/ cls = NSButton.cellClass (); /* use our custom cell class */ + long /*int*/ cls = NSButton.cellClass (); /* use our custom cell class */ buttonCell = new NSButtonCell (OS.class_createInstance (cls, 0)); buttonCell.init (); checkColumn.setDataCell (buttonCell); @@ -675,7 +675,7 @@ void deregister () { if (buttonCell != null) display.removeWidget (buttonCell); } -void deselectAll(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void deselectAll(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { if (preventSelect && !ignoreSelect) return; if ((style & SWT.SINGLE) != 0 && !ignoreSelect) { if ( ((NSTableView)view).selectedRow() != -1) return; @@ -683,7 +683,7 @@ void deselectAll(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { super.deselectAll (id, sel, sender); } -void deselectRow (int /*long*/ id, int /*long*/ sel, int /*long*/ index) { +void deselectRow (long /*int*/ id, long /*int*/ sel, long /*int*/ index) { if (preventSelect && !ignoreSelect) return; if ((style & SWT.SINGLE) != 0 && !ignoreSelect) { if ( ((NSTableView)view).selectedRow() == index) return; @@ -878,7 +878,7 @@ void destroyItem (TableColumn column) { NSArray array = ((NSTableView)view).tableColumns (); int arraySize = (int)/*64*/array.count (); for (int i = oldIndex; i < arraySize; i++) { - int /*long*/ columnId = array.objectAtIndex (i).id; + long /*int*/ columnId = array.objectAtIndex (i).id; for (int j = 0; j < columnCount; j++) { if (columns[j].nsColumn.id == columnId) { columns [j].sendEvent (SWT.Move); @@ -906,13 +906,13 @@ boolean dragDetect(int x, int y, boolean filter, boolean[] consume) { return false; } -void drawBackgroundInClipRect(int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawBackgroundInClipRect(long /*int*/ id, long /*int*/ sel, NSRect rect) { super.drawViewBackgroundInRect(id, sel, rect); if (id != view.id) return; fillBackground (view, NSGraphicsContext.currentContext(), rect, -1); } -void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rect, int /*long*/ view) { +void drawInteriorWithFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect rect, long /*int*/ view) { boolean hooksErase = hooks (SWT.EraseItem); boolean hooksPaint = hooks (SWT.PaintItem); boolean hooksMeasure = hooks (SWT.MeasureItem); @@ -920,13 +920,13 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec NSTextFieldCell cell = new NSTextFieldCell (id); NSTableView widget = (NSTableView)this.view; - int /*long*/ [] outValue = new int /*long*/ [1]; + long /*int*/ [] outValue = new long /*int*/ [1]; OS.object_getInstanceVariable(id, Display.SWT_ROW, outValue); - int /*long*/ rowIndex = outValue [0]; + long /*int*/ rowIndex = outValue [0]; TableItem item = _getItem((int)/*64*/rowIndex); OS.object_getInstanceVariable(id, Display.SWT_COLUMN, outValue); - int /*long*/ tableColumn = outValue[0]; - int /*long*/ nsColumnIndex = widget.tableColumns().indexOfObjectIdenticalTo(new id(tableColumn)); + long /*int*/ tableColumn = outValue[0]; + long /*int*/ nsColumnIndex = widget.tableColumns().indexOfObjectIdenticalTo(new id(tableColumn)); int columnIndex = 0; for (int i=0; i<columnCount; i++) { if (columns [i].nsColumn.id == tableColumn) { @@ -963,7 +963,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec NSRect rowRect = widget.rectOfRow (rowIndex); cellRect.width = rowRect.width; } - float /*double*/ offsetX = 0, offsetY = 0; + double /*float*/ offsetX = 0, offsetY = 0; if (hooksPaint || hooksErase) { NSRect frameCell = widget.frameOfCellAtColumn(nsColumnIndex, rowIndex); offsetX = rect.x - frameCell.x; @@ -1044,7 +1044,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec if (drawBackground && !drawSelection) { context.saveGraphicsState (); - float /*double*/ [] colorRGB = background.handle; + double /*float*/ [] colorRGB = background.handle; NSColor color = NSColor.colorWithDeviceRed (colorRGB[0], colorRGB[1], colorRGB[2], 1f); color.setFill (); NSBezierPath.fillRect (cellRect); @@ -1078,7 +1078,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec * foreground color to black when the cell is highlighted. The text * still draws white. The fix is to draw the text and not call super. */ - float /*double*/ [] color = userForeground.handle; + double /*float*/ [] color = userForeground.handle; if (color[0] == 0 && color[1] == 0 && color[2] == 0 && color[3] == 1) { NSMutableAttributedString newStr = new NSMutableAttributedString(cell.attributedStringValue().mutableCopy()); NSRange range = new NSRange(); @@ -1161,7 +1161,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec } } -void drawWithExpansionFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cellFrame, int /*long*/ view) { +void drawWithExpansionFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect cellFrame, long /*int*/ view) { drawExpansion = true; super.drawWithExpansionFrame_inView(id, sel, cellFrame, view); drawExpansion = false; @@ -1177,7 +1177,7 @@ void drawRect(int id, int sel, NSRect rect) { } } -NSRect expansionFrameWithFrame_inView(int /*long*/ id, int /*long*/ sel, NSRect cellRect, int /*long*/ view) { +NSRect expansionFrameWithFrame_inView(long /*int*/ id, long /*int*/ sel, NSRect cellRect, long /*int*/ view) { if (toolTipText == null) { NSRect rect = super.expansionFrameWithFrame_inView(id, sel, cellRect, view); NSCell cell = new NSCell(id); @@ -1225,7 +1225,7 @@ Widget findTooltip (NSPoint pt) { NSTableHeaderView headerView = widget.headerView(); if (headerView != null) { pt = headerView.convertPoint_fromView_ (pt, null); - int /*long*/ index = headerView.columnAtPoint (pt); + long /*int*/ index = headerView.columnAtPoint (pt); if (index != -1) { NSArray nsColumns = widget.tableColumns (); id nsColumn = nsColumns.objectAtIndex (index); @@ -1631,7 +1631,7 @@ public TableItem [] getSelection () { } NSIndexSet selection = widget.selectedRowIndexes(); int count = (int)/*64*/selection.count(); - int /*long*/ [] indexBuffer = new int /*long*/ [count]; + long /*int*/ [] indexBuffer = new long /*int*/ [count]; selection.getIndexes(indexBuffer, count, 0); TableItem [] result = new TableItem [count]; for (int i=0; i<count; i++) { @@ -1674,7 +1674,7 @@ public int getSelectionIndex () { } NSIndexSet selection = widget.selectedRowIndexes(); int count = (int)/*64*/selection.count(); - int /*long*/ [] result = new int /*long*/ [count]; + long /*int*/ [] result = new long /*int*/ [count]; selection.getIndexes(result, count, 0); return (int)/*64*/result [0]; } @@ -1703,7 +1703,7 @@ public int [] getSelectionIndices () { } NSIndexSet selection = widget.selectedRowIndexes(); int count = (int)/*64*/selection.count(); - int /*long*/ [] indices = new int /*long*/ [count]; + long /*int*/ [] indices = new long /*int*/ [count]; selection.getIndexes(indices, count, 0); int [] result = new int [count]; for (int i = 0; i < indices.length; i++) { @@ -1779,7 +1779,7 @@ public int getTopIndex () { return rowAtPoint; } -NSRect headerRectOfColumn (int /*long*/ id, int /*long*/ sel, int /*long*/ column) { +NSRect headerRectOfColumn (long /*int*/ id, long /*int*/ sel, long /*int*/ column) { if ((style & SWT.CHECK) == 0) return callSuperRect(id, sel, column); if (column == 0) { @@ -1797,7 +1797,7 @@ NSRect headerRectOfColumn (int /*long*/ id, int /*long*/ sel, int /*long*/ colum return callSuperRect(id, sel, column); } -void highlightSelectionInClipRect(int /*long*/ id, int /*long*/ sel, int /*long*/ rect) { +void highlightSelectionInClipRect(long /*int*/ id, long /*int*/ sel, long /*int*/ rect) { if (hooks (SWT.EraseItem)) return; if ((style & SWT.HIDE_SELECTION) != 0 && !hasFocus()) return; NSRect clipRect = new NSRect (); @@ -1805,7 +1805,7 @@ void highlightSelectionInClipRect(int /*long*/ id, int /*long*/ sel, int /*long* callSuper (id, sel, clipRect); } -int /*long*/ hitTestForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event, NSRect rect, int /*long*/ controlView) { +long /*int*/ hitTestForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event, NSRect rect, long /*int*/ controlView) { /* * For some reason, the cell class needs to implement hitTestForEvent:inRect:ofView:, * otherwise the double action selector is not called properly. @@ -1813,13 +1813,13 @@ int /*long*/ hitTestForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ ev return callSuper(id, sel, event, rect, controlView); } -int /*long*/ image (int /*long*/ id, int /*long*/ sel) { - int /*long*/ [] image = new int /*long*/ [1]; +long /*int*/ image (long /*int*/ id, long /*int*/ sel) { + long /*int*/ [] image = new long /*int*/ [1]; OS.object_getInstanceVariable(id, Display.SWT_IMAGE, image); return image[0]; } -NSRect imageRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSRect imageRectForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { NSImage image = new NSCell(id).image(); if (image != null) { cellFrame.x += IMAGE_GAP; @@ -1919,7 +1919,7 @@ boolean isTransparent() { return true; } -void keyDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { ignoreSelect = preventSelect = false; super.keyDown(id, sel, theEvent); } @@ -1929,7 +1929,7 @@ boolean isTrim (NSView view) { return view.id == headerView.id; } -int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +long /*int*/ menuForEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (id != headerView.id) { /* * Feature in Cocoa: Table views do not change the selection when the user @@ -1944,7 +1944,7 @@ int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEve // select the row that was clicked before showing the menu for the event NSPoint mousePoint = view.convertPoint_fromView_(event.locationInWindow(), null); - int /*long*/ row = table.rowAtPoint(mousePoint); + long /*int*/ row = table.rowAtPoint(mousePoint); // figure out if the row that was just clicked on is currently selected if (selectedRowIndexes.containsIndex(row) == false) { @@ -1958,7 +1958,7 @@ int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEve return super.menuForEvent(id, sel, theEvent); } -void mouseDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (id == view.id) { // Bug/feature in Cocoa: If the table has a context menu we just set it visible instead of returning // it from menuForEvent:. This has the side effect, however, of sending control-click to the NSTableView, @@ -1970,7 +1970,7 @@ void mouseDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { super.mouseDown(id, sel, theEvent); } -void mouseDownSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDownSuper(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { ignoreSelect = preventSelect = false; boolean check = false; NSEvent nsEvent = new NSEvent(theEvent); @@ -1999,7 +1999,7 @@ void mouseDownSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { didSelect = false; } -boolean needsPanelToBecomeKey (int /*long*/ id, int /*long*/ sel) { +boolean needsPanelToBecomeKey (long /*int*/ id, long /*int*/ sel) { return false; } @@ -2009,7 +2009,7 @@ boolean needsPanelToBecomeKey (int /*long*/ id, int /*long*/ sel) { * to momentarily appear while clicking on the checkbox. To avoid this, * override [NSCell nextState] to go directly to the desired state. */ -int /*long*/ nextState (int /*long*/ id, int /*long*/ sel) { +long /*int*/ nextState (long /*int*/ id, long /*int*/ sel) { NSTableView tableView = (NSTableView)view; int index = (int)/*64*/tableView.clickedRow(); if (index == -1) index = (int)/*64*/tableView.selectedRow (); @@ -2020,7 +2020,7 @@ int /*long*/ nextState (int /*long*/ id, int /*long*/ sel) { return item.checked ? OS.NSOffState : OS.NSOnState; } -int /*long*/ numberOfRowsInTableView(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView) { +long /*int*/ numberOfRowsInTableView(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView) { return itemCount; } @@ -2266,7 +2266,7 @@ void reskinChildren (int flags) { super.reskinChildren (flags); } -void scrollClipViewToPoint(int /*long*/ id, int /*long*/ sel, int /*long*/ clipView, NSPoint point) { +void scrollClipViewToPoint(long /*int*/ id, long /*int*/ sel, long /*int*/ clipView, NSPoint point) { if (shouldScroll) { super.scrollClipViewToPoint(id, sel, clipView, point); if ((style & SWT.CHECK) != 0 && columnCount > 0 && ((NSTableView)view).headerView() != null) { @@ -2533,7 +2533,7 @@ public void setHeaderVisible (boolean show) { scrollView.tile(); } -void setImage (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void setImage (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { OS.object_setInstanceVariable(id, Display.SWT_IMAGE, arg0); } @@ -2591,8 +2591,8 @@ public void setItemCount (int count) { void setItemHeight (Image image, NSFont font, boolean set) { if (font == null) font = getFont ().handle; - float /*double*/ ascent = font.ascender (); - float /*double*/ descent = -font.descender () + font.leading (); + double /*float*/ ascent = font.ascender (); + double /*float*/ descent = -font.descender () + font.leading (); int height = (int)Math.ceil (ascent + descent) + 1; Rectangle bounds = image != null ? image.getBounds () : imageBounds; if (bounds != null) { @@ -2859,7 +2859,7 @@ public void setSelection (TableItem [] items) { } } -void setShouldScrollClipView(int /*long*/ id, int /*long*/ sel, boolean shouldScroll) { +void setShouldScrollClipView(long /*int*/ id, long /*int*/ sel, boolean shouldScroll) { this.shouldScroll = shouldScroll; } @@ -3035,7 +3035,7 @@ public void showSelection () { } } -void selectRowIndexes_byExtendingSelection (int /*long*/ id, int /*long*/ sel, int /*long*/ indexes, boolean extend) { +void selectRowIndexes_byExtendingSelection (long /*int*/ id, long /*int*/ sel, long /*int*/ indexes, boolean extend) { if (preventSelect && !ignoreSelect) return; if ((style & SWT.SINGLE) != 0 && !ignoreSelect) { NSIndexSet set = new NSIndexSet(indexes); @@ -3113,7 +3113,7 @@ void sendMeasureItem (TableItem item, int columnIndex, NSSize size, boolean isSe } } -void tableViewColumnDidMove (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewColumnDidMove (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { NSNotification notification = new NSNotification (aNotification); NSDictionary userInfo = notification.userInfo (); NSString nsstring = (NSString) new NSString().alloc(); @@ -3141,7 +3141,7 @@ void tableViewColumnDidMove (int /*long*/ id, int /*long*/ sel, int /*long*/ aNo headerView.setNeedsDisplay(true); } -void tableViewColumnDidResize (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewColumnDidResize (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { NSNotification notification = new NSNotification (aNotification); NSDictionary userInfo = notification.userInfo (); NSString nsstring = (NSString) new NSString().alloc(); @@ -3185,23 +3185,23 @@ void sendSelection () { } } -void tableViewSelectionDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewSelectionDidChange (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { if (didSelect) return; sendSelection(); } -void tableViewSelectionIsChanging (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewSelectionIsChanging (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { didSelect = true; sendSelection(); } -void tableView_didClickTableColumn (int /*long*/ id, int /*long*/ sel, int /*long*/ tableView, int /*long*/ tableColumn) { +void tableView_didClickTableColumn (long /*int*/ id, long /*int*/ sel, long /*int*/ tableView, long /*int*/ tableColumn) { TableColumn column = getColumn (new id (tableColumn)); if (column == null) return; /* either CHECK column or firstColumn in 0-column Table */ column.sendSelectionEvent (SWT.Selection); } -int /*long*/ tableView_objectValueForTableColumn_row (int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ aTableColumn, int /*long*/ rowIndex) { +long /*int*/ tableView_objectValueForTableColumn_row (long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ aTableColumn, long /*int*/ rowIndex) { int index = (int)/*64*/rowIndex; TableItem item = _getItem (index); checkData (item, index); @@ -3222,7 +3222,7 @@ int /*long*/ tableView_objectValueForTableColumn_row (int /*long*/ id, int /*lon return item.createString (0).id; } -boolean tableView_shouldReorderColumn_toColumn(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ currentColIndex, int /*long*/ newColIndex) { +boolean tableView_shouldReorderColumn_toColumn(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ currentColIndex, long /*int*/ newColIndex) { // Check column should never move and no column can be dragged to the left of it, if present. if ((style & SWT.CHECK) != 0) { if (currentColIndex == 0) return false; @@ -3240,7 +3240,7 @@ boolean tableView_shouldReorderColumn_toColumn(int /*long*/ id, int /*long*/ sel return true; } -boolean tableView_shouldTrackCell_forTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ table, int /*long*/ cell, /*long*/ int /*long*/ tableColumn, int /*long*/ rowIndex) { +boolean tableView_shouldTrackCell_forTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ table, long /*int*/ cell, /*long*/ long /*int*/ tableColumn, long /*int*/ rowIndex) { if ((style & SWT.CHECK) != 0) { if (new NSCell(cell).isKindOfClass(OS.class_NSButtonCell)) return true; } @@ -3248,7 +3248,7 @@ boolean tableView_shouldTrackCell_forTableColumn_row(int /*long*/ id, int /*long return widget.isRowSelected(rowIndex); } -void tableView_setObjectValue_forTableColumn_row (int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ anObject, int /*long*/ aTableColumn, int /*long*/ rowIndex) { +void tableView_setObjectValue_forTableColumn_row (long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ anObject, long /*int*/ aTableColumn, long /*int*/ rowIndex) { if (checkColumn != null && aTableColumn == checkColumn.id) { TableItem item = items [(int)/*64*/rowIndex]; item.checked = !item.checked; @@ -3261,7 +3261,7 @@ void tableView_setObjectValue_forTableColumn_row (int /*long*/ id, int /*long*/ } } -void tableView_willDisplayCell_forTableColumn_row (int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ cell, int /*long*/ tableColumn, int /*long*/ rowIndex) { +void tableView_willDisplayCell_forTableColumn_row (long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ cell, long /*int*/ tableColumn, long /*int*/ rowIndex) { if (checkColumn != null && tableColumn == checkColumn.id) return; TableItem item = items [(int)/*64*/rowIndex]; int index = 0; @@ -3326,7 +3326,7 @@ void tableView_willDisplayCell_forTableColumn_row (int /*long*/ id, int /*long*/ } } -boolean tableView_writeRowsWithIndexes_toPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2) { +boolean tableView_writeRowsWithIndexes_toPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) { return sendMouseEvent(NSApplication.sharedApplication().currentEvent(), SWT.DragDetect, true); } @@ -3338,7 +3338,7 @@ boolean sendMouseEvent(NSEvent nsEvent, int type, boolean send) { NSTableView widget = (NSTableView)view; NSIndexSet selectedRows = widget.selectedRowIndexes (); int count = (int)/*64*/selectedRows.count(); - int /*long*/ [] indexBuffer = new int /*long*/ [count]; + long /*int*/ [] indexBuffer = new long /*int*/ [count]; selectedRows.getIndexes(indexBuffer, count, 0); for (int i = 0; i < count; i++) { if (indexBuffer[i] == selectedRowIndex) continue; @@ -3358,7 +3358,7 @@ boolean sendMouseEvent(NSEvent nsEvent, int type, boolean send) { return super.sendMouseEvent (nsEvent, type, send); } -NSRect titleRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSRect titleRectForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { NSImage image = new NSCell(id).image(); if (image != null) { int imageWidth = imageBounds.width + IMAGE_GAP; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TableColumn.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TableColumn.java index a4332b1964..118528dc6f 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TableColumn.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TableColumn.java @@ -201,7 +201,7 @@ void destroyWidget () { releaseHandle (); } -void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cellRect, int /*long*/ view) { +void drawInteriorWithFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect cellRect, long /*int*/ view) { /* * Feature in Cocoa. When the last column in a table does not reach the * rightmost edge of the table view, the cell that draws the rightmost- diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Text.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Text.java index ad5506dd13..41bf9eea28 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Text.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Text.java @@ -61,7 +61,7 @@ public class Text extends Scrollable { String message; NSRange selectionRange; id targetSearch, targetCancel; - int /*long*/ actionSearch, actionCancel; + long /*int*/ actionSearch, actionCancel; /** * The maximum number of characters that can be entered @@ -337,7 +337,7 @@ public void append (String string) { if (string.length () != 0) sendEvent (SWT.Modify); } -boolean becomeFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean becomeFirstResponder (long /*int*/ id, long /*int*/ sel) { receivingFocus = true; boolean result = super.becomeFirstResponder (id, sel); receivingFocus = false; @@ -575,9 +575,9 @@ void createWidget () { super.createWidget (); if ((style & SWT.PASSWORD) != 0) { NSText fieldEditor = view.window().fieldEditor(true, view); - int /*long*/ nsSecureTextViewClass = OS.objc_lookUpClass("NSSecureTextView"); + long /*int*/ nsSecureTextViewClass = OS.objc_lookUpClass("NSSecureTextView"); if (fieldEditor != null && nsSecureTextViewClass != 0 && fieldEditor.isKindOfClass(nsSecureTextViewClass)) { - int /*long*/ editorClass = OS.objc_getClass("SWTSecureEditorView"); + long /*int*/ editorClass = OS.objc_getClass("SWTSecureEditorView"); OS.object_setClass(fieldEditor.id, editorClass); } } @@ -657,7 +657,7 @@ void deregister() { } } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if ((style & SWT.SINGLE) != 0) { if (backgroundImage == null) return; if (new NSView(id).isKindOfClass(OS.class_NSText)) { @@ -684,7 +684,7 @@ void drawInteriorWithFrame_inView(int id, int sel, NSRect cellFrame, int viewid) boolean dragDetect (int x, int y, boolean filter, boolean [] consume) { Point selection = getSelection (); if (selection.x != selection.y) { - int /*long*/ position = getPosition (x, y); + long /*int*/ position = getPosition (x, y); if (selection.x <= position && position < selection.y) { if (super.dragDetect (x, y, filter, consume)) { if (consume != null) consume [0] = true; @@ -727,7 +727,7 @@ public int getCaretLineNumber () { return (getTopPixel () + getCaretLocation ().y) / getLineHeight (); } -boolean acceptsFirstResponder(int /*long*/ id, int /*long*/ sel) { +boolean acceptsFirstResponder(long /*int*/ id, long /*int*/ sel) { if ((style & SWT.READ_ONLY) != 0) return true; return super.acceptsFirstResponder(id, sel); } @@ -757,8 +757,8 @@ public Point getCaretLocation () { NSLayoutManager layoutManager = widget.layoutManager(); NSTextContainer container = widget.textContainer(); NSRange range = widget.selectedRange(); - int /*long*/ [] rectCount = new int /*long*/ [1]; - int /*long*/ pArray = layoutManager.rectArrayForCharacterRange(range, range, container, rectCount); + long /*int*/ [] rectCount = new long /*int*/ [1]; + long /*int*/ pArray = layoutManager.rectArrayForCharacterRange(range, range, container, rectCount); NSRect rect = new NSRect(); if (rectCount[0] > 0) OS.memmove(rect, pArray, NSRect.sizeof); return new Point((int)rect.x, (int)rect.y); @@ -939,7 +939,7 @@ public int getLineCount () { NSTextStorage storage = ((NSTextView) view).textStorage (); int count = (int)/*64*/storage.paragraphs ().count (); NSString string = storage.string(); - int /*long*/ length = string.length(), c; + long /*int*/ length = string.length(), c; if (length == 0 || (c = string.characterAtIndex(length - 1)) == '\n' || c == '\r') { count++; } @@ -1028,7 +1028,7 @@ public String getMessage () { return message; } -int /*long*/ getPosition (int /*long*/ x, int /*long*/ y) { +long /*int*/ getPosition (long /*int*/ x, long /*int*/ y) { // checkWidget (); if ((style & SWT.MULTI) != 0) { NSTextView widget = (NSTextView) view; @@ -1374,7 +1374,7 @@ void insertEditText (String string) { } } -boolean isEventView (int /*long*/ id) { +boolean isEventView (long /*int*/ id) { if ((style & SWT.MULTI) != 0) return super.isEventView (id); return true; } @@ -1595,7 +1595,7 @@ boolean sendKeyEvent (NSEvent nsEvent, int type) { boolean result = super.sendKeyEvent (nsEvent, type); if (!result) return result; if (type != SWT.KeyDown) return result; - int /*long*/ modifierFlags = nsEvent.modifierFlags(); + long /*int*/ modifierFlags = nsEvent.modifierFlags(); if ((modifierFlags & OS.NSCommandKeyMask) != 0) { short keyCode = nsEvent.keyCode (); switch (keyCode) { @@ -1792,7 +1792,7 @@ void setEditText (char[] text) { selectionRange = null; } -void setFrameSize(int /*long*/ id, int /*long*/ sel, NSSize size) { +void setFrameSize(long /*int*/ id, long /*int*/ sel, NSSize size) { super.setFrameSize (id, sel, size); /* * Bug in Cocoa. When a search field is resized while having @@ -1820,13 +1820,13 @@ void setFont(NSFont font) { super.setFont (font); } -void setForeground (float /*double*/ [] color) { +void setForeground (double /*float*/ [] color) { NSColor nsColor; if (color == null) { nsColor = NSColor.textColor (); if ((style & SWT.MULTI) != 0 && !isEnabled()) nsColor = NSColor.disabledControlTextColor(); } else { - float /*double*/ alpha = 1; + double /*float*/ alpha = 1; if ((style & SWT.MULTI) != 0 && !isEnabled()) alpha = 0.5f; nsColor = NSColor.colorWithDeviceRed (color [0], color [1], color [2], alpha); } @@ -2036,7 +2036,7 @@ public void setTabs (int tabs) { if (this.tabs == tabs) return; this.tabs = tabs; if ((style & SWT.SINGLE) != 0) return; - float /*double*/ size = textExtent("s").width * tabs; + double /*float*/ size = textExtent("s").width * tabs; NSTextView widget = (NSTextView)view; NSParagraphStyle defaultStyle = widget.defaultParagraphStyle(); NSMutableParagraphStyle paragraphStyle = new NSMutableParagraphStyle(defaultStyle.mutableCopy()); @@ -2189,7 +2189,7 @@ public void setTopIndex (int index) { view.scrollPoint(pt); } -boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ sel, int /*long*/ affectedCharRange, int /*long*/ replacementString) { +boolean shouldChangeTextInRange_replacementString(long /*int*/ id, long /*int*/ sel, long /*int*/ affectedCharRange, long /*int*/ replacementString) { NSRange range = new NSRange(); OS.memmove(range, affectedCharRange, NSRange.sizeof); boolean result = callSuperBoolean(id, sel, range, replacementString); @@ -2204,7 +2204,7 @@ boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ String newText = text; if (hooks (SWT.Verify)) { NSEvent currentEvent = display.application.currentEvent(); - int /*long*/ type = currentEvent.type(); + long /*int*/ type = currentEvent.type(); if (type != OS.NSKeyDown && type != OS.NSKeyUp) currentEvent = null; newText = verifyText(text, (int)/*64*/range.location, (int)/*64*/(range.location+range.length), currentEvent); } @@ -2256,18 +2256,18 @@ public void showSelection () { } } -void textViewDidChangeSelection(int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textViewDidChangeSelection(long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { NSNotification notification = new NSNotification (aNotification); NSText editor = new NSText (notification.object ().id); selectionRange = editor.selectedRange (); } -void textDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textDidChange (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { if ((style & SWT.SINGLE) != 0) super.textDidChange (id, sel, aNotification); postEvent (SWT.Modify); } -NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange (int /*long*/ id, int /*long*/ sel, int /*long*/ aTextView, int /*long*/ oldSelectedCharRange, int /*long*/ newSelectedCharRange) { +NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange (long /*int*/ id, long /*int*/ sel, long /*int*/ aTextView, long /*int*/ oldSelectedCharRange, long /*int*/ newSelectedCharRange) { /* * If the selection is changing as a result of the receiver getting focus * then return the receiver's last selection range, otherwise the full @@ -2287,7 +2287,7 @@ int traversalCode (int key, NSEvent theEvent) { if ((style & SWT.MULTI) != 0) { bits &= ~SWT.TRAVERSE_RETURN; if (key == 48 /* Tab */ && theEvent != null) { - int /*long*/ modifiers = theEvent.modifierFlags (); + long /*int*/ modifiers = theEvent.modifierFlags (); boolean next = (modifiers & OS.NSShiftKeyMask) == 0; if (next && (modifiers & OS.NSControlKeyMask) == 0) { bits &= ~(SWT.TRAVERSE_TAB_NEXT | SWT.TRAVERSE_TAB_PREVIOUS); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolBar.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolBar.java index 4de8091353..f8c9306125 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolBar.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolBar.java @@ -107,7 +107,7 @@ ToolBar(Composite parent, int style, boolean internal) { } } -int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityAttributeValue (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { NSString nsAttributeName = new NSString(arg0); if (id == accessibleHandle() && accessible != null) { @@ -121,7 +121,7 @@ int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int if (nsAttributeName.isEqualToString (OS.NSAccessibilityRoleAttribute)) return role.id; else { - int /*long*/ roleDescription = OS.NSAccessibilityRoleDescription(role.id, 0); + long /*int*/ roleDescription = OS.NSAccessibilityRoleDescription(role.id, 0); return roleDescription; } } else if (nsAttributeName.isEqualToString(OS.NSAccessibilityChildrenAttribute)) { @@ -141,7 +141,7 @@ int /*long*/ accessibilityAttributeValue (int /*long*/ id, int /*long*/ sel, int return super.accessibilityAttributeValue(id, sel, arg0); } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { // Toolbars aren't ignored. if (id == view.id) return false; return super.accessibilityIsIgnored(id, sel); @@ -313,7 +313,7 @@ void destroyItem (ToolItem item) { relayout (); } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id != view.id) return; if (background != null) { fillBackground (view, context, rect, -1); @@ -742,7 +742,7 @@ public void setVisible(boolean visible) { super.setVisible(visible); } -int /*long*/ toolbar_itemForItemIdentifier_willBeInsertedIntoToolbar(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar, int /*long*/ itemIdentifier, boolean flag) { +long /*int*/ toolbar_itemForItemIdentifier_willBeInsertedIntoToolbar(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar, long /*int*/ itemIdentifier, boolean flag) { NSString itemID = new NSString(itemIdentifier); for (int j = 0; j < itemCount; j++) { ToolItem item = items[j]; @@ -757,7 +757,7 @@ int /*long*/ toolbar_itemForItemIdentifier_willBeInsertedIntoToolbar(int /*long* * Returns an array of all toolbar item IDs allowed to be in the toolbar. Since the ToolBar created all of the ToolItems * return all of the item IDs. */ -int /*long*/ toolbarAllowedItemIdentifiers(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar) { +long /*int*/ toolbarAllowedItemIdentifiers(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar) { NSMutableArray array = NSMutableArray.arrayWithCapacity(itemCount); for (int i = 0; i < itemCount; i++) { array.addObject(items[i].nsItem.itemIdentifier()); @@ -768,7 +768,7 @@ int /*long*/ toolbarAllowedItemIdentifiers(int /*long*/ id, int /*long*/ sel, in /* * This delegate method isn't really needed because ToolBars aren't customizable, but it's required according to the documentation. */ -int /*long*/ toolbarDefaultItemIdentifiers(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar) { +long /*int*/ toolbarDefaultItemIdentifiers(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar) { return toolbarAllowedItemIdentifiers(id, sel, toolbar); } @@ -776,7 +776,7 @@ int /*long*/ toolbarDefaultItemIdentifiers(int /*long*/ id, int /*long*/ sel, in * toolbarSelectableItemIdentifiers returns an array of all items that can be the selected item, as determined * by setSelectedItemIdentifier. */ -int /*long*/ toolbarSelectableItemIdentifiers(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar) { +long /*int*/ toolbarSelectableItemIdentifiers(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar) { NSMutableArray array = NSMutableArray.arrayWithCapacity(itemCount); for (int i = 0; i < itemCount; i++) { if ((items[i].style & SWT.RADIO) != 0) array.addObject(items[i].nsItem.itemIdentifier()); diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolItem.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolItem.java index ad7d0f29ea..03ece4e218 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolItem.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/ToolItem.java @@ -137,15 +137,15 @@ public ToolItem (ToolBar parent, int style, int index) { parent.createItem (this, index); } -int /*long*/ accessibleHandle() { +long /*int*/ accessibleHandle() { if (button != null && button.cell() != null) return button.cell().id; if (view != null) return view.id; return 0; } -int /*long*/ accessibilityActionNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityActionNames(long /*int*/ id, long /*int*/ sel) { - int /*long*/ returnValue = super.accessibilityActionNames(id, sel); + long /*int*/ returnValue = super.accessibilityActionNames(id, sel); if (id == accessibleHandle()) { if ((style & SWT.DROP_DOWN) != 0) { @@ -161,9 +161,9 @@ int /*long*/ accessibilityActionNames(int /*long*/ id, int /*long*/ sel) { return returnValue; } -int /*long*/ accessibilityAttributeNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityAttributeNames(long /*int*/ id, long /*int*/ sel) { - int /*long*/ returnValue = super.accessibilityAttributeNames(id, sel); + long /*int*/ returnValue = super.accessibilityAttributeNames(id, sel); if (id == accessibleHandle()) { if ((style & (SWT.CHECK|SWT.RADIO)) !=0) { @@ -185,7 +185,7 @@ int /*long*/ accessibilityAttributeNames(int /*long*/ id, int /*long*/ sel) { return returnValue; } -int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityAttributeValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { NSString nsAttributeName = new NSString(arg0); if (nsAttributeName.isEqualToString (OS.NSAccessibilityRoleAttribute) || nsAttributeName.isEqualToString (OS.NSAccessibilityRoleDescriptionAttribute)) { @@ -198,7 +198,7 @@ int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int if (nsAttributeName.isEqualToString (OS.NSAccessibilityRoleAttribute)) { return roleText.id; } else { // NSAccessibilityRoleDescriptionAttribute - int /*long*/ description = OS.NSAccessibilityRoleDescription (roleText.id, 0); + long /*int*/ description = OS.NSAccessibilityRoleDescription (roleText.id, 0); return description; } } @@ -234,7 +234,7 @@ int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int return super.accessibilityAttributeValue(id, sel, arg0); } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { // The interesting part of a ToolItem is its button, if it has one. if (id == accessibleHandle()) return false; return super.accessibilityIsIgnored(id, sel); @@ -412,7 +412,7 @@ void destroyWidget() { super.destroyWidget(); } -void drawImageWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ image, NSRect rect, int /*long*/ view) { +void drawImageWithFrameInView (long /*int*/ id, long /*int*/ sel, long /*int*/ image, NSRect rect, long /*int*/ view) { if (text.length () > 0) { if ((parent.style & SWT.RIGHT) != 0) { rect.x += 3; @@ -420,7 +420,7 @@ void drawImageWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ i rect.y += 3; } } - int /*long*/ cgContext = NSGraphicsContext.currentContext().graphicsPort(); + long /*int*/ cgContext = NSGraphicsContext.currentContext().graphicsPort(); NSCell cell = new NSCell(id); boolean drawSelected = (parent.nsToolbar != null) && getSelection() && ((style & SWT.CHECK) != 0) && !cell.isHighlighted(); @@ -444,7 +444,7 @@ void drawImageWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ i } } -NSRect drawTitleWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ title, NSRect titleRect, int /*long*/ view) { +NSRect drawTitleWithFrameInView (long /*int*/ id, long /*int*/ sel, long /*int*/ title, NSRect titleRect, long /*int*/ view) { boolean hiliteShadow = new NSButtonCell(id).isHighlighted() && text.length() > 0 && image == null; // An unbordered cell doesn't draw any highlighting when pushed or selected, so we have to do it here. @@ -462,7 +462,7 @@ NSRect drawTitleWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ return super.drawTitleWithFrameInView(id, sel, title, titleRect, view); } -void drawWidget (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawWidget (long /*int*/ id, NSGraphicsContext context, NSRect rect) { if (id == view.id) { boolean drawSelected = getSelection() && (parent.nsToolbar == null); if (drawSelected) { @@ -732,11 +732,11 @@ boolean isDrawing () { return getDrawing() && parent.isDrawing (); } -int /*long*/ menuForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +long /*int*/ menuForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { return parent.menuForEvent (id, sel, theEvent); } -void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseDown)) return; Display display = this.display; display.trackingControl = parent; @@ -752,47 +752,47 @@ void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { } } -boolean mouseDownCanMoveWindow(int /*long*/ id, int /*long*/ sel) { +boolean mouseDownCanMoveWindow(long /*int*/ id, long /*int*/ sel) { if (id == view.id) return false; return super.mouseDownCanMoveWindow(id, sel); } -void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseUp)) return; super.mouseUp(id, sel, theEvent); } -void mouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseMove)) return; super.mouseDragged(id, sel, theEvent); } -void rightMouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseDown)) return; super.rightMouseDown(id, sel, theEvent); } -void rightMouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseUp)) return; super.rightMouseUp(id, sel, theEvent); } -void rightMouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseMove)) return; super.rightMouseDragged(id, sel, theEvent); } -void otherMouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseDown)) return; super.otherMouseDown(id, sel, theEvent); } -void otherMouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseUp)) return; super.otherMouseUp(id, sel, theEvent); } -void otherMouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (!parent.mouseEvent(parent.view.id, sel, theEvent, SWT.MouseMove)) return; super.otherMouseDragged(id, sel, theEvent); } @@ -1263,7 +1263,7 @@ void updateImage (boolean layout) { parent.relayout(); } -boolean validateMenuItem(int /*long*/ id, int /*long*/ sel, int /*long*/ menuItem) { +boolean validateMenuItem(long /*int*/ id, long /*int*/ sel, long /*int*/ menuItem) { return isEnabled(); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tracker.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tracker.java index 6a2d14c908..127ce11cf0 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tracker.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tracker.java @@ -365,7 +365,7 @@ void drawRectangles (NSWindow window, Rectangle [] rects, boolean erase) { context.setCompositingOperation(erase ? OS.NSCompositeClear : OS.NSCompositeSourceOver); NSRect rectFrame = new NSRect(); NSPoint globalPoint = new NSPoint(); - float /*double*/ screenHeight = display.getPrimaryFrame().height; + double /*float*/ screenHeight = display.getPrimaryFrame().height; for (int i=0; i<rects.length; i++) { Rectangle rect = rects [i]; rectFrame.x = rect.x + parentOrigin.x; @@ -551,7 +551,7 @@ void mouse (NSEvent nsEvent) { void key (NSEvent nsEvent) { int nsType = (int)/*64*/nsEvent.type(); - int /*long*/ modifierFlags = nsEvent.modifierFlags(); + long /*int*/ modifierFlags = nsEvent.modifierFlags(); int nsKeyCode = nsEvent.keyCode(); int keyCode = Display.translateKey (nsKeyCode); @@ -755,14 +755,14 @@ public boolean open () { tracking = true; window = (NSWindow)new NSWindow().alloc(); NSArray screens = NSScreen.screens(); - float /*double*/ minX = Float.MAX_VALUE, maxX = Float.MIN_VALUE; - float /*double*/ minY = Float.MAX_VALUE, maxY = Float.MIN_VALUE; + double /*float*/ minX = Float.MAX_VALUE, maxX = Float.MIN_VALUE; + double /*float*/ minY = Float.MAX_VALUE, maxY = Float.MIN_VALUE; int count = (int)/*64*/screens.count(); for (int i = 0; i < count; i++) { NSScreen screen = new NSScreen(screens.objectAtIndex(i)); NSRect frame = screen.frame(); - float /*double*/ x1 = frame.x, x2 = frame.x + frame.width; - float /*double*/ y1 = frame.y, y2 = frame.y + frame.height; + double /*float*/ x1 = frame.x, x2 = frame.x + frame.width; + double /*float*/ y1 = frame.y, y2 = frame.y + frame.height; if (x1 < minX) minX = x1; if (x2 < minX) minX = x2; if (x1 > maxX) maxX = x1; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TrayItem.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TrayItem.java index 78f7dff12a..5193ef1026 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TrayItem.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TrayItem.java @@ -513,7 +513,7 @@ boolean shouldShowMenu (NSEvent event) { return false; } -void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { NSEvent nsEvent = new NSEvent(theEvent); highlight = true; updateImage(); @@ -524,7 +524,7 @@ void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { } } -void mouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { NSEvent nsEvent = new NSEvent(theEvent); NSRect frame = view.frame(); boolean oldHighlight = highlight; @@ -539,7 +539,7 @@ void mouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { } } -void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (highlight) { NSEvent nsEvent = new NSEvent(theEvent); if (nsEvent.type() == OS.NSLeftMouseUp) { @@ -551,25 +551,25 @@ void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { view.setNeedsDisplay(true); } -void rightMouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { mouseDown(id, sel, theEvent); } -void rightMouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { mouseUp(id, sel, theEvent); } -void rightMouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { mouseDragged(id, sel, theEvent); } -void drawRect(int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawRect(long /*int*/ id, long /*int*/ sel, NSRect rect) { item.drawStatusBarBackgroundInRect(rect, highlight); super.drawRect(id, sel, rect); } void updateImage () { - float /*double*/ width = 0; + double /*float*/ width = 0; Image image = this.image; if (highlight && highlightImage != null) image = highlightImage; if (image == null) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tree.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tree.java index ccfa08c883..871d7c2716 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tree.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Tree.java @@ -159,19 +159,19 @@ TreeItem _getItem (TreeItem parentItem, int index, boolean create) { return item; } -boolean acceptsFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean acceptsFirstResponder (long /*int*/ id, long /*int*/ sel) { return true; } -int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { - int /*long*/ returnValue = 0; +long /*int*/ accessibilityAttributeValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { + long /*int*/ returnValue = 0; NSString attributeName = new NSString(arg0); // If the check column is visible, don't report it back as a column for accessibility purposes. // The check column is meant to appear as a part of the first column. if (attributeName.isEqualToString (OS.NSAccessibilityColumnsAttribute) || attributeName.isEqualToString(OS.NSAccessibilityVisibleColumnsAttribute)) { if ((style & SWT.CHECK) != 0) { - int /*long*/ superValue = super.accessibilityAttributeValue(id, sel, arg0); + long /*int*/ superValue = super.accessibilityAttributeValue(id, sel, arg0); if (superValue != 0) { NSArray columns = new NSArray(superValue); NSMutableArray columnsWithoutCheck = NSMutableArray.arrayWithCapacity(columns.count() - 1); @@ -267,17 +267,17 @@ int calculateWidth (TreeItem[] items, int index, GC gc, boolean recurse) { return width; } -NSSize cellSize (int /*long*/ id, int /*long*/ sel) { +NSSize cellSize (long /*int*/ id, long /*int*/ sel) { NSSize size = super.cellSize(id, sel); NSCell cell = new NSCell(id); NSImage image = cell.image(); if (image != null) size.width += imageBounds.width + IMAGE_GAP; if (hooks(SWT.MeasureItem)) { - int /*long*/ [] outValue = new int /*long*/ [1]; + long /*int*/ [] outValue = new long /*int*/ [1]; OS.object_getInstanceVariable(id, Display.SWT_ROW, outValue); TreeItem item = (TreeItem) display.getWidget (outValue [0]); OS.object_getInstanceVariable(id, Display.SWT_COLUMN, outValue); - int /*long*/ tableColumn = outValue[0]; + long /*int*/ tableColumn = outValue[0]; int columnIndex = 0; for (int i=0; i<columnCount; i++) { if (columns [i].nsColumn.id == tableColumn) { @@ -290,13 +290,13 @@ NSSize cellSize (int /*long*/ id, int /*long*/ sel) { return size; } -boolean canDragRowsWithIndexes_atPoint(int /*long*/ id, int /*long*/ sel, int /*long*/ rowIndexes, NSPoint mouseDownPoint) { +boolean canDragRowsWithIndexes_atPoint(long /*int*/ id, long /*int*/ sel, long /*int*/ rowIndexes, NSPoint mouseDownPoint) { if (!super.canDragRowsWithIndexes_atPoint(id, sel, rowIndexes, mouseDownPoint)) return false; // If the current row is not selected and the user is not attempting to modify the selection, select the row first. NSTableView widget = (NSTableView)view; - int /*long*/ row = widget.rowAtPoint(mouseDownPoint); - int /*long*/ modifiers = NSApplication.sharedApplication().currentEvent().modifierFlags(); + long /*int*/ row = widget.rowAtPoint(mouseDownPoint); + long /*int*/ modifiers = NSApplication.sharedApplication().currentEvent().modifierFlags(); boolean drag = (state & DRAG_DETECT) != 0 && hooks (SWT.DragDetect); if (drag) { @@ -454,7 +454,7 @@ void clearCachedWidth (TreeItem[] items) { } } -void collapseItem_collapseChildren (int /*long*/ id, int /*long*/ sel, int /*long*/ itemID, boolean children) { +void collapseItem_collapseChildren (long /*int*/ id, long /*int*/ sel, long /*int*/ itemID, boolean children) { TreeItem item = (TreeItem)display.getWidget(itemID); if (item == null) return; if (!ignoreExpand) item.sendExpand (false, children); @@ -465,7 +465,7 @@ void collapseItem_collapseChildren (int /*long*/ id, int /*long*/ sel, int /*lon setScrollWidth (); } -int /*long*/ columnAtPoint(int /*long*/ id, int /*long*/ sel, NSPoint point) { +long /*int*/ columnAtPoint(long /*int*/ id, long /*int*/ sel, NSPoint point) { if ((style & SWT.CHECK) != 0) { if (point.x <= getCheckColumnWidth() && point.y < headerView.frame().height) return 1; } @@ -589,7 +589,7 @@ void createHandle () { widget.setOutlineTableColumn (checkColumn); checkColumn.setResizingMask (OS.NSTableColumnNoResizing); checkColumn.setEditable (false); - int /*long*/ cls = NSButton.cellClass (); /* use our custom cell class */ + long /*int*/ cls = NSButton.cellClass (); /* use our custom cell class */ buttonCell = new NSButtonCell (OS.class_createInstance (cls, 0)); buttonCell.init (); checkColumn.setDataCell (buttonCell); @@ -753,7 +753,7 @@ Color defaultForeground () { return display.getWidgetColor (SWT.COLOR_LIST_FOREGROUND); } -void deselectAll(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void deselectAll(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { if (preventSelect && !ignoreSelect) return; if ((style & SWT.SINGLE) != 0 && !ignoreSelect) { if ( ((NSTableView)view).selectedRow() != -1) return; @@ -761,7 +761,7 @@ void deselectAll(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { super.deselectAll (id, sel, sender); } -void deselectRow (int /*long*/ id, int /*long*/ sel, int /*long*/ index) { +void deselectRow (long /*int*/ id, long /*int*/ sel, long /*int*/ index) { if (preventSelect && !ignoreSelect) return; if ((style & SWT.SINGLE) != 0 && !ignoreSelect) { if ( ((NSTableView)view).selectedRow() == index) return; @@ -814,7 +814,7 @@ public void deselect (TreeItem item) { if (item == null) error (SWT.ERROR_NULL_ARGUMENT); if (item.isDisposed ()) error (SWT.ERROR_INVALID_ARGUMENT); NSOutlineView widget = (NSOutlineView)view; - int /*long*/ row = widget.rowForItem(item.handle); + long /*int*/ row = widget.rowForItem(item.handle); ignoreSelect = true; widget.deselectRow (row); ignoreSelect = false; @@ -911,7 +911,7 @@ void destroyItem (TreeColumn column) { NSArray array = ((NSOutlineView)view).tableColumns (); int arraySize = (int)/*64*/array.count (); for (int i = oldIndex; i < arraySize; i++) { - int /*long*/ columnId = array.objectAtIndex (i).id; + long /*int*/ columnId = array.objectAtIndex (i).id; for (int j = 0; j < columnCount; j++) { if (columns[j].nsColumn.id == columnId) { columns [j].sendEvent (SWT.Move); @@ -964,13 +964,13 @@ boolean dragDetect(int x, int y, boolean filter, boolean[] consume) { return false; } -void drawBackgroundInClipRect(int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawBackgroundInClipRect(long /*int*/ id, long /*int*/ sel, NSRect rect) { super.drawViewBackgroundInRect(id, sel, rect); if (id != view.id) return; fillBackground (view, NSGraphicsContext.currentContext(), rect, -1); } -void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rect, int /*long*/ view) { +void drawInteriorWithFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect rect, long /*int*/ view) { boolean hooksErase = hooks (SWT.EraseItem); boolean hooksPaint = hooks (SWT.PaintItem); boolean hooksMeasure = hooks (SWT.MeasureItem); @@ -978,14 +978,14 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec NSTextFieldCell cell = new NSTextFieldCell (id); NSOutlineView widget = (NSOutlineView)this.view; - int /*long*/ [] outValue = new int /*long*/ [1]; + long /*int*/ [] outValue = new long /*int*/ [1]; OS.object_getInstanceVariable(id, Display.SWT_ROW, outValue); TreeItem item = (TreeItem) display.getWidget (outValue [0]); if (item == null) return; - int /*long*/ rowIndex = widget.rowForItem(item.handle); + long /*int*/ rowIndex = widget.rowForItem(item.handle); OS.object_getInstanceVariable(id, Display.SWT_COLUMN, outValue); - int /*long*/ tableColumn = outValue[0]; - int /*long*/ nsColumnIndex = widget.tableColumns().indexOfObjectIdenticalTo(new id(tableColumn)); + long /*int*/ tableColumn = outValue[0]; + long /*int*/ nsColumnIndex = widget.tableColumns().indexOfObjectIdenticalTo(new id(tableColumn)); int columnIndex = 0; for (int i=0; i<columnCount; i++) { if (columns [i].nsColumn.id == tableColumn) { @@ -1022,7 +1022,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec NSRect rowRect = widget.rectOfRow (rowIndex); cellRect.width = rowRect.width; } - float /*double*/ offsetX = 0, offsetY = 0; + double /*float*/ offsetX = 0, offsetY = 0; if (hooksPaint || hooksErase) { NSRect frameCell = widget.frameOfCellAtColumn(nsColumnIndex, rowIndex); offsetX = rect.x - frameCell.x; @@ -1104,7 +1104,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec if (drawBackground && !drawSelection) { context.saveGraphicsState (); - float /*double*/ [] colorRGB = background.handle; + double /*float*/ [] colorRGB = background.handle; NSColor color = NSColor.colorWithDeviceRed (colorRGB[0], colorRGB[1], colorRGB[2], 1f); color.setFill (); NSBezierPath.fillRect (cellRect); @@ -1158,7 +1158,7 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec * foreground color to black when the cell is highlighted. The text * still draws white. The fix is to draw the text and not call super. */ - float /*double*/ [] color = userForeground.handle; + double /*float*/ [] color = userForeground.handle; if (color[0] == 0 && color[1] == 0 && color[2] == 0 && color[3] == 1) { NSMutableAttributedString newStr = new NSMutableAttributedString(cell.attributedStringValue().mutableCopy()); NSRange range = new NSRange(); @@ -1241,13 +1241,13 @@ void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect rec } } -void drawWithExpansionFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cellFrame, int /*long*/ view) { +void drawWithExpansionFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect cellFrame, long /*int*/ view) { drawExpansion = true; super.drawWithExpansionFrame_inView(id, sel, cellFrame, view); drawExpansion = false; } -void expandItem_expandChildren (int /*long*/ id, int /*long*/ sel, int /*long*/ itemID, boolean children) { +void expandItem_expandChildren (long /*int*/ id, long /*int*/ sel, long /*int*/ itemID, boolean children) { TreeItem item = (TreeItem)display.getWidget(itemID); if (item == null) return; if (!ignoreExpand) item.sendExpand (true, children); @@ -1266,7 +1266,7 @@ void expandItem_expandChildren (int /*long*/ id, int /*long*/ sel, int /*long*/ setScrollWidth (false, item.items, true); } -NSRect expansionFrameWithFrame_inView(int /*long*/ id, int /*long*/ sel, NSRect cellRect, int /*long*/ view) { +NSRect expansionFrameWithFrame_inView(long /*int*/ id, long /*int*/ sel, NSRect cellRect, long /*int*/ view) { if (toolTipText == null) { NSRect rect = super.expansionFrameWithFrame_inView(id, sel, cellRect, view); NSCell cell = new NSCell(id); @@ -1314,7 +1314,7 @@ Widget findTooltip (NSPoint pt) { NSTableHeaderView headerView = widget.headerView(); if (headerView != null) { pt = headerView.convertPoint_fromView_ (pt, null); - int /*long*/ index = headerView.columnAtPoint (pt); + long /*int*/ index = headerView.columnAtPoint (pt); if (index != -1) { NSArray nsColumns = widget.tableColumns (); id nsColumn = nsColumns.objectAtIndex (index); @@ -1745,7 +1745,7 @@ public TreeItem [] getSelection () { } NSIndexSet selection = widget.selectedRowIndexes (); int count = (int)/*64*/selection.count (); - int /*long*/ [] indexBuffer = new int /*long*/ [count]; + long /*int*/ [] indexBuffer = new long /*int*/ [count]; selection.getIndexes (indexBuffer, count, 0); TreeItem [] result = new TreeItem [count]; for (int i=0; i<count; i++) { @@ -1837,13 +1837,13 @@ public TreeItem getTopItem () { point.x = rect.x; point.y = rect.y; NSOutlineView outlineView = (NSOutlineView)view; - int /*long*/ index = outlineView.rowAtPoint (point); + long /*int*/ index = outlineView.rowAtPoint (point); if (index == -1) return null; /* empty */ id item = outlineView.itemAtRow (index); return (TreeItem)display.getWidget (item.id); } -NSRect headerRectOfColumn (int /*long*/ id, int /*long*/ sel, int /*long*/ column) { +NSRect headerRectOfColumn (long /*int*/ id, long /*int*/ sel, long /*int*/ column) { if ((style & SWT.CHECK) == 0) return callSuperRect(id, sel, column); if (column == 0) { @@ -1861,7 +1861,7 @@ NSRect headerRectOfColumn (int /*long*/ id, int /*long*/ sel, int /*long*/ colum return callSuperRect(id, sel, column); } -void highlightSelectionInClipRect(int /*long*/ id, int /*long*/ sel, int /*long*/ rect) { +void highlightSelectionInClipRect(long /*int*/ id, long /*int*/ sel, long /*int*/ rect) { if (hooks (SWT.EraseItem)) return; if ((style & SWT.HIDE_SELECTION) != 0 && !hasFocus()) return; NSRect clipRect = new NSRect (); @@ -1869,7 +1869,7 @@ void highlightSelectionInClipRect(int /*long*/ id, int /*long*/ sel, int /*long* callSuper (id, sel, clipRect); } -int /*long*/ hitTestForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event, NSRect rect, int /*long*/ controlView) { +long /*int*/ hitTestForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event, NSRect rect, long /*int*/ controlView) { /* * For some reason, the cell class needs to implement hitTestForEvent:inRect:ofView:, * otherwise the double action selector is not called properly. @@ -1877,13 +1877,13 @@ int /*long*/ hitTestForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ ev return callSuper(id, sel, event, rect, controlView); } -int /*long*/ image (int /*long*/ id, int /*long*/ sel) { - int /*long*/ [] image = new int /*long*/ [1]; +long /*int*/ image (long /*int*/ id, long /*int*/ sel) { + long /*int*/ [] image = new long /*int*/ [1]; OS.object_getInstanceVariable(id, Display.SWT_IMAGE, image); return image[0]; } -NSRect imageRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSRect imageRectForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { NSImage image = new NSCell(id).image(); if (image != null) { cellFrame.x += IMAGE_GAP; @@ -1966,12 +1966,12 @@ boolean isTrim (NSView view) { return view.id == headerView.id; } -void keyDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { ignoreSelect = preventSelect = false; super.keyDown(id, sel, theEvent); } -int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +long /*int*/ menuForEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (id != headerView.id) { /* * Feature in Cocoa: Table views do not change the selection when the user @@ -1986,7 +1986,7 @@ int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEve // select the row that was clicked before showing the menu for the event NSPoint mousePoint = view.convertPoint_fromView_(event.locationInWindow(), null); - int /*long*/ row = tree.rowAtPoint(mousePoint); + long /*int*/ row = tree.rowAtPoint(mousePoint); // figure out if the row that was just clicked on is currently selected if (selectedRowIndexes.containsIndex(row) == false) { @@ -2001,7 +2001,7 @@ int /*long*/ menuForEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ theEve return super.menuForEvent(id, sel, theEvent); } -void mouseDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { if (id == view.id) { // Bug/feature in Cocoa: If the tree has a context menu we just set it visible instead of returning // it from menuForEvent:. This has the side effect, however, of sending control-click to the NSTableView, @@ -2012,7 +2012,7 @@ void mouseDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { super.mouseDown(id, sel, theEvent); } -void mouseDownSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDownSuper(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { ignoreSelect = preventSelect = false; boolean check = false; NSEvent nsEvent = new NSEvent(theEvent); @@ -2049,7 +2049,7 @@ void mouseDownSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { didSelect = false; } -boolean needsPanelToBecomeKey (int /*long*/ id, int /*long*/ sel) { +boolean needsPanelToBecomeKey (long /*int*/ id, long /*int*/ sel) { return false; } @@ -2059,7 +2059,7 @@ boolean needsPanelToBecomeKey (int /*long*/ id, int /*long*/ sel) { * to momentarily appear while clicking on the checkbox. To avoid this, * override [NSCell nextState] to go directly to the desired state. */ -int /*long*/ nextState (int /*long*/ id, int /*long*/ sel) { +long /*int*/ nextState (long /*int*/ id, long /*int*/ sel) { NSOutlineView outlineView = (NSOutlineView)view; int index = (int)/*64*/outlineView.clickedRow(); if (index == -1) index = (int)/*64*/outlineView.selectedRow (); @@ -2070,19 +2070,19 @@ int /*long*/ nextState (int /*long*/ id, int /*long*/ sel) { return item.checked ? OS.NSOffState : OS.NSOnState; } -int /*long*/ outlineView_child_ofItem (int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ index, int /*long*/ itemID) { +long /*int*/ outlineView_child_ofItem (long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ index, long /*int*/ itemID) { TreeItem parent = (TreeItem) display.getWidget (itemID); TreeItem item = _getItem (parent, (int)/*64*/index, true); return item.handle.id; } -void outlineView_didClickTableColumn (int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ tableColumn) { +void outlineView_didClickTableColumn (long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ tableColumn) { TreeColumn column = getColumn (new id (tableColumn)); if (column == null) return; /* either CHECK column or firstColumn in 0-column Tree */ column.sendSelectionEvent (SWT.Selection); } -int /*long*/ outlineView_objectValueForTableColumn_byItem (int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ tableColumn, int /*long*/ itemID) { +long /*int*/ outlineView_objectValueForTableColumn_byItem (long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ tableColumn, long /*int*/ itemID) { TreeItem item = (TreeItem) display.getWidget (itemID); checkData (item); if (checkColumn != null && tableColumn == checkColumn.id) { @@ -2102,21 +2102,21 @@ int /*long*/ outlineView_objectValueForTableColumn_byItem (int /*long*/ id, int return item.createString (0).id; } -boolean outlineView_isItemExpandable (int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ item) { +boolean outlineView_isItemExpandable (long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ item) { if (item == 0) return true; return ((TreeItem) display.getWidget (item)).itemCount != 0; } -int /*long*/ outlineView_numberOfChildrenOfItem (int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ item) { +long /*int*/ outlineView_numberOfChildrenOfItem (long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ item) { if (item == 0) return itemCount; return ((TreeItem) display.getWidget (item)).itemCount; } -boolean outlineView_shouldExpandItem_item (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +boolean outlineView_shouldExpandItem_item (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { return shouldExpand; } -boolean outlineView_shouldReorderColumn_toColumn(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ currentColIndex, int /*long*/ newColIndex) { +boolean outlineView_shouldReorderColumn_toColumn(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ currentColIndex, long /*int*/ newColIndex) { // Check column should never move and no column can be dragged to the left of it, if present. if ((style & SWT.CHECK) != 0) { if (currentColIndex == 0) return false; @@ -2134,16 +2134,16 @@ boolean outlineView_shouldReorderColumn_toColumn(int /*long*/ id, int /*long*/ s return true; } -boolean outlineView_shouldTrackCell_forTableColumn_item(int /*long*/ id, int /*long*/ sel, int /*long*/ table, int /*long*/ cell, int /*long*/ tableColumn, int /*long*/ item) { +boolean outlineView_shouldTrackCell_forTableColumn_item(long /*int*/ id, long /*int*/ sel, long /*int*/ table, long /*int*/ cell, long /*int*/ tableColumn, long /*int*/ item) { if ((style & SWT.CHECK) != 0) { if (new NSCell(cell).isKindOfClass(OS.class_NSButtonCell)) return true; } NSOutlineView widget = (NSOutlineView)view; - int /*long*/ rowIndex = widget.rowForItem(new id(item)); + long /*int*/ rowIndex = widget.rowForItem(new id(item)); return widget.isRowSelected(rowIndex); } -void outlineView_willDisplayCell_forTableColumn_item (int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ cell, int /*long*/ tableColumn, int /*long*/ itemID) { +void outlineView_willDisplayCell_forTableColumn_item (long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ cell, long /*int*/ tableColumn, long /*int*/ itemID) { if (checkColumn != null && tableColumn == checkColumn.id) return; TreeItem item = (TreeItem) display.getWidget(itemID); int index = 0; @@ -2208,7 +2208,7 @@ void outlineView_willDisplayCell_forTableColumn_item (int /*long*/ id, int /*lon } } -void outlineViewColumnDidMove (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void outlineViewColumnDidMove (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { NSNotification notification = new NSNotification (aNotification); NSDictionary userInfo = notification.userInfo (); NSString nsstring = (NSString) new NSString().alloc(); @@ -2236,7 +2236,7 @@ void outlineViewColumnDidMove (int /*long*/ id, int /*long*/ sel, int /*long*/ a headerView.setNeedsDisplay(true); } -void outlineViewColumnDidResize (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void outlineViewColumnDidResize (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { NSNotification notification = new NSNotification (aNotification); NSDictionary userInfo = notification.userInfo (); NSString nsstring = (NSString) new NSString().alloc(); @@ -2265,7 +2265,7 @@ void outlineViewColumnDidResize (int /*long*/ id, int /*long*/ sel, int /*long*/ } } -void scrollClipViewToPoint (int /*long*/ id, int /*long*/ sel, int /*long*/ clipView, NSPoint point) { +void scrollClipViewToPoint (long /*int*/ id, long /*int*/ sel, long /*int*/ clipView, NSPoint point) { if (shouldScroll) { super.scrollClipViewToPoint(id, sel, clipView, point); if ((style & SWT.CHECK) != 0 && columnCount > 0 && ((NSOutlineView) view).headerView () != null) { @@ -2296,17 +2296,17 @@ void sendSelection () { } } -void outlineViewSelectionDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void outlineViewSelectionDidChange (long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { if (didSelect) return; sendSelection (); } -void outlineViewSelectionIsChanging (int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void outlineViewSelectionIsChanging (long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { didSelect = true; sendSelection (); } -void outlineView_setObjectValue_forTableColumn_byItem (int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ object, int /*long*/ tableColumn, int /*long*/ itemID) { +void outlineView_setObjectValue_forTableColumn_byItem (long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ object, long /*int*/ tableColumn, long /*int*/ itemID) { if (checkColumn != null && tableColumn == checkColumn.id) { TreeItem item = (TreeItem) display.getWidget (itemID); item.checked = !item.checked; @@ -2318,7 +2318,7 @@ void outlineView_setObjectValue_forTableColumn_byItem (int /*long*/ id, int /*lo } } -boolean outlineView_writeItems_toPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2) { +boolean outlineView_writeItems_toPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) { return sendMouseEvent(NSApplication.sharedApplication().currentEvent(), SWT.DragDetect, true); } @@ -2463,7 +2463,7 @@ void reskinChildren (int flags) { super.reskinChildren (flags); } -void setImage (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void setImage (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { OS.object_setInstanceVariable(id, Display.SWT_IMAGE, arg0); } @@ -2539,7 +2539,7 @@ public void select (TreeItem item) { checkItems (); showItem (item); NSOutlineView outlineView = (NSOutlineView) view; - int /*long*/ row = outlineView.rowForItem (item.handle); + long /*int*/ row = outlineView.rowForItem (item.handle); NSIndexSet set = (NSIndexSet)new NSIndexSet().alloc(); set = set.initWithIndex(row); ignoreSelect = true; @@ -2548,7 +2548,7 @@ public void select (TreeItem item) { set.release(); } -void selectRowIndexes_byExtendingSelection (int /*long*/ id, int /*long*/ sel, int /*long*/ indexes, boolean extend) { +void selectRowIndexes_byExtendingSelection (long /*int*/ id, long /*int*/ sel, long /*int*/ indexes, boolean extend) { if (preventSelect && !ignoreSelect) return; if ((style & SWT.SINGLE) != 0 && !ignoreSelect) { NSIndexSet set = new NSIndexSet(indexes); @@ -2636,7 +2636,7 @@ boolean sendMouseEvent(NSEvent nsEvent, int type, boolean send) { NSTableView widget = (NSTableView)view; NSIndexSet selectedRows = widget.selectedRowIndexes (); int count = (int)/*64*/selectedRows.count(); - int /*long*/ [] indexBuffer = new int /*long*/ [count]; + long /*int*/ [] indexBuffer = new long /*int*/ [count]; selectedRows.getIndexes(indexBuffer, count, 0); for (int i = 0; i < count; i++) { if (indexBuffer[i] == selectedRowIndex) continue; @@ -2677,7 +2677,7 @@ void selectItems (TreeItem[] items, boolean ignoreDisposed) { set.release(); } -NSRect titleRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSRect titleRectForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { NSImage image = new NSCell(id).image(); if (image != null) { int imageWidth = imageBounds.width + IMAGE_GAP; @@ -2892,8 +2892,8 @@ void setItemCount (TreeItem parentItem, int count) { void setItemHeight (Image image, NSFont font, boolean set) { if (font == null) font = getFont ().handle; - float /*double*/ ascent = font.ascender (); - float /*double*/ descent = -font.descender () + font.leading (); + double /*float*/ ascent = font.ascender (); + double /*float*/ descent = -font.descender () + font.leading (); int height = (int)Math.ceil (ascent + descent) + 1; Rectangle bounds = image != null ? image.getBounds () : imageBounds; if (bounds != null) { @@ -2977,11 +2977,11 @@ boolean setScrollWidth (TreeItem item) { return false; } -void setShouldExpandItem (int /*long*/ id, int /*long*/ sel, boolean shouldExpand) { +void setShouldExpandItem (long /*int*/ id, long /*int*/ sel, boolean shouldExpand) { this.shouldExpand = shouldExpand; } -void setShouldScrollClipView (int /*long*/ id, int /*long*/ sel, boolean shouldScroll) { +void setShouldScrollClipView (long /*int*/ id, long /*int*/ sel, boolean shouldScroll) { this.shouldScroll = shouldScroll; } @@ -3143,7 +3143,7 @@ public void setTopItem (TreeItem item) { checkItems (); showItem (item, false); NSOutlineView widget = (NSOutlineView) view; - int /*long*/ row = widget.rowForItem (item.handle); + long /*int*/ row = widget.rowForItem (item.handle); if (row == -1) return; NSPoint pt = new NSPoint(); pt.x = scrollView.contentView().bounds().x; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TreeColumn.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TreeColumn.java index 0a0f469257..28e09a02e5 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TreeColumn.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/TreeColumn.java @@ -203,7 +203,7 @@ void destroyWidget () { releaseHandle (); } -void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cellRect, int /*long*/ view) { +void drawInteriorWithFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect cellRect, long /*int*/ view) { /* * Feature in Cocoa. When the last column in a tree does not reach the * rightmost edge of the tree view, the cell that draws the rightmost- diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java index d3f6668a63..5a24c9a716 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Widget.java @@ -48,7 +48,7 @@ public abstract class Widget { EventTable eventTable; Object data; - int /*long*/ jniRef; + long /*int*/ jniRef; /* Global state flags */ static final int DISPOSED = 1 << 0; @@ -135,61 +135,61 @@ public Widget (Widget parent, int style) { reskinWidget (); } -int /*long*/ accessibleHandle() { +long /*int*/ accessibleHandle() { return 0; } -int /*long*/ accessibilityActionDescription(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityActionDescription(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { return callSuperObject(id, sel, arg0); } -int /*long*/ accessibilityActionNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityActionNames(long /*int*/ id, long /*int*/ sel) { return callSuperObject(id, sel); } -int /*long*/ accessibilityAttributeNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityAttributeNames(long /*int*/ id, long /*int*/ sel) { return callSuperObject(id, sel); } -int /*long*/ accessibilityAttributeValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ accessibilityAttributeValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { return callSuperObject(id, sel, arg0); } -int /*long*/ accessibilityAttributeValue_forParameter(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +long /*int*/ accessibilityAttributeValue_forParameter(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, arg0, arg1); } -int /*long*/ accessibilityFocusedUIElement(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityFocusedUIElement(long /*int*/ id, long /*int*/ sel) { return callSuperObject(id, sel); } -int /*long*/ accessibilityHitTest(int /*long*/ id, int /*long*/ sel, NSPoint point) { +long /*int*/ accessibilityHitTest(long /*int*/ id, long /*int*/ sel, NSPoint point) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, point); } -boolean accessibilityIsAttributeSettable(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +boolean accessibilityIsAttributeSettable(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { return callSuperBoolean(id, sel, arg0); } -boolean accessibilityIsIgnored(int /*long*/ id, int /*long*/ sel) { +boolean accessibilityIsIgnored(long /*int*/ id, long /*int*/ sel) { return callSuperBoolean(id, sel); } -int /*long*/ accessibilityParameterizedAttributeNames(int /*long*/ id, int /*long*/ sel) { +long /*int*/ accessibilityParameterizedAttributeNames(long /*int*/ id, long /*int*/ sel) { return callSuperObject(id, sel); } -void accessibilityPerformAction(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void accessibilityPerformAction(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { callSuper(id, sel, arg0); } -void accessibilitySetValue_forAttribute(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +void accessibilitySetValue_forAttribute(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { callSuper(id, sel, arg0, arg1); } @@ -203,71 +203,71 @@ String getClipboardText () { void setClipRegion (NSView view) { } -int /*long*/ attributedSubstringFromRange (int /*long*/ id, int /*long*/ sel, int /*long*/ range) { +long /*int*/ attributedSubstringFromRange (long /*int*/ id, long /*int*/ sel, long /*int*/ range) { return 0; } -void callSuper(int /*long*/ id, int /*long*/ sel) { +void callSuper(long /*int*/ id, long /*int*/ sel) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel); } -void callSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void callSuper(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, arg0); } -void callSuper(int /*long*/ id, int /*long*/ sel, NSRect arg0) { +void callSuper(long /*int*/ id, long /*int*/ sel, NSRect arg0) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, arg0); } -void callSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +void callSuper(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, arg0, arg1); } -void callSuper(int /*long*/ id, int /*long*/ sel, NSRect arg0, int /*long*/ arg1) { +void callSuper(long /*int*/ id, long /*int*/ sel, NSRect arg0, long /*int*/ arg1) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, arg0, arg1); } -int /*long*/ callSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, NSRect arg1, int /*long*/ arg2) { +long /*int*/ callSuper(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, NSRect arg1, long /*int*/ arg2) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, arg0, arg1, arg2); } -boolean callSuperBoolean(int /*long*/ id, int /*long*/ sel) { +boolean callSuperBoolean(long /*int*/ id, long /*int*/ sel) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel) != 0; } -boolean canBecomeKeyWindow (int /*long*/ id, int /*long*/ sel) { +boolean canBecomeKeyWindow (long /*int*/ id, long /*int*/ sel) { return callSuperBoolean (id, sel); } -boolean needsPanelToBecomeKey (int /*long*/ id, int /*long*/ sel) { +boolean needsPanelToBecomeKey (long /*int*/ id, long /*int*/ sel) { return callSuperBoolean (id, sel); } -void cancelOperation(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void cancelOperation(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { } -NSSize cellSize (int /*long*/ id, int /*long*/ sel) { +NSSize cellSize (long /*int*/ id, long /*int*/ sel) { NSSize result = new NSSize(); objc_super super_struct = new objc_super(); super_struct.receiver = id; @@ -276,7 +276,7 @@ NSSize cellSize (int /*long*/ id, int /*long*/ sel) { return result; } -NSSize cellSizeForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSSize cellSizeForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -285,42 +285,42 @@ NSSize cellSizeForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { return result; } -boolean callSuperBoolean(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +boolean callSuperBoolean(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, arg0) != 0; } -boolean callSuperBoolean(int /*long*/ id, int /*long*/ sel, NSRange range, int /*long*/ arg1) { +boolean callSuperBoolean(long /*int*/ id, long /*int*/ sel, NSRange range, long /*int*/ arg1) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper_bool(super_struct, sel, range, arg1); } -int /*long*/ callSuperObject(int /*long*/ id, int /*long*/ sel) { +long /*int*/ callSuperObject(long /*int*/ id, long /*int*/ sel) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel); } -int /*long*/ callSuperObject(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +long /*int*/ callSuperObject(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, arg0); } -int /*long*/ callSuperObject(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +long /*int*/ callSuperObject(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, arg0, arg1); } -NSRect callSuperRect(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +NSRect callSuperRect(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -329,40 +329,40 @@ NSRect callSuperRect(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { return result; } -boolean canDragRowsWithIndexes_atPoint(int /*long*/ id, int /*long*/ sel, int /*long*/ rowIndexes, NSPoint mouseDownPoint) { +boolean canDragRowsWithIndexes_atPoint(long /*int*/ id, long /*int*/ sel, long /*int*/ rowIndexes, NSPoint mouseDownPoint) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper_bool(super_struct, sel, rowIndexes, mouseDownPoint); } -int /*long*/ characterIndexForPoint (int /*long*/ id, int /*long*/ sel, int /*long*/ point) { +long /*int*/ characterIndexForPoint (long /*int*/ id, long /*int*/ sel, long /*int*/ point) { return OS.NSNotFound; } -int /*long*/ columnAtPoint(int /*long*/ id, int /*long*/ sel, NSPoint point) { +long /*int*/ columnAtPoint(long /*int*/ id, long /*int*/ sel, NSPoint point) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, point); } -boolean acceptsFirstMouse (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +boolean acceptsFirstMouse (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, theEvent) != 0; } -boolean acceptsFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean acceptsFirstResponder (long /*int*/ id, long /*int*/ sel) { return callSuperBoolean(id, sel); } -boolean becomeFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean becomeFirstResponder (long /*int*/ id, long /*int*/ sel) { return callSuperBoolean(id, sel); } -void becomeKeyWindow (int /*long*/ id, int /*long*/ sel) { +void becomeKeyWindow (long /*int*/ id, long /*int*/ sel) { callSuper(id, sel); } @@ -410,7 +410,7 @@ void reskinWidget() { } } -boolean resignFirstResponder (int /*long*/ id, int /*long*/ sel) { +boolean resignFirstResponder (long /*int*/ id, long /*int*/ sel) { return callSuperBoolean(id, sel); } @@ -475,7 +475,7 @@ public void addDisposeListener (DisposeListener listener) { addListener (SWT.Dispose, typedListener); } -boolean canBecomeKeyView(int /*long*/ id, int /*long*/ sel) { +boolean canBecomeKeyView(long /*int*/ id, long /*int*/ sel) { return true; } @@ -575,14 +575,14 @@ protected void checkWidget () { if ((state & DISPOSED) != 0) error (SWT.ERROR_WIDGET_DISPOSED); } -void clearDeferFlushing (int /*long*/ id, int /*long*/ sel) { +void clearDeferFlushing (long /*int*/ id, long /*int*/ sel) { } -boolean textView_clickOnLink_atIndex(int /*long*/ id, int /*long*/ sel, int /*long*/ textView, int /*long*/ link, int /*long*/ charIndex) { +boolean textView_clickOnLink_atIndex(long /*int*/ id, long /*int*/ sel, long /*int*/ textView, long /*int*/ link, long /*int*/ charIndex) { return true; } -void collapseItem_collapseChildren (int /*long*/ id, int /*long*/ sel, int /*long*/ item, boolean children) { +void collapseItem_collapseChildren (long /*int*/ id, long /*int*/ sel, long /*int*/ item, boolean children) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -612,13 +612,13 @@ void createWidget () { register (); } -void comboBoxSelectionDidChange(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void comboBoxSelectionDidChange(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void comboBoxWillDismiss(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void comboBoxWillDismiss(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void comboBoxWillPopUp(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void comboBoxWillPopUp(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } void deregister () { @@ -667,35 +667,35 @@ public void dispose () { release (true); } -void deselectAll(int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void deselectAll(long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { callSuper(id, sel, sender); } -void deselectRow(int /*long*/ id, int /*long*/ sel, int /*long*/ index) { +void deselectRow(long /*int*/ id, long /*int*/ sel, long /*int*/ index) { callSuper(id, sel, index); } -void doCommandBySelector (int /*long*/ id, int /*long*/ sel, int /*long*/ aSelector) { +void doCommandBySelector (long /*int*/ id, long /*int*/ sel, long /*int*/ aSelector) { callSuper (id, sel, aSelector); } -boolean dragSelectionWithEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2) { +boolean dragSelectionWithEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) { return false; } -void drawBackground (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawBackground (long /*int*/ id, NSGraphicsContext context, NSRect rect) { /* Do nothing */ } -void drawBackgroundInClipRect(int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawBackgroundInClipRect(long /*int*/ id, long /*int*/ sel, NSRect rect) { callSuper(id, sel, rect); } -void drawImageWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ image, NSRect rect, int /*long*/ view) { +void drawImageWithFrameInView (long /*int*/ id, long /*int*/ sel, long /*int*/ image, NSRect rect, long /*int*/ view) { callSuper(id, sel, image, rect, view); } -NSRect drawTitleWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ title, NSRect rect, int /*long*/ view) { +NSRect drawTitleWithFrameInView (long /*int*/ id, long /*int*/ sel, long /*int*/ title, NSRect rect, long /*int*/ view) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -704,26 +704,26 @@ NSRect drawTitleWithFrameInView (int /*long*/ id, int /*long*/ sel, int /*long*/ return result; } -void drawInteriorWithFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cellFrame, int /*long*/ view) { +void drawInteriorWithFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect cellFrame, long /*int*/ view) { callSuper(id, sel, cellFrame, view); } -void drawLabelInRect(int /*long*/ id, int /*long*/ sel, boolean shouldTruncateLabel, NSRect rect) { +void drawLabelInRect(long /*int*/ id, long /*int*/ sel, boolean shouldTruncateLabel, NSRect rect) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, shouldTruncateLabel, rect); } -void drawViewBackgroundInRect(int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawViewBackgroundInRect(long /*int*/ id, long /*int*/ sel, NSRect rect) { callSuper(id, sel, rect); } -void drawWithExpansionFrame_inView (int /*long*/ id, int /*long*/ sel, NSRect cellFrame, int /*long*/ view) { +void drawWithExpansionFrame_inView (long /*int*/ id, long /*int*/ sel, NSRect cellFrame, long /*int*/ view) { callSuper(id, sel, cellFrame, view); } -void drawRect (int /*long*/ id, int /*long*/ sel, NSRect rect) { +void drawRect (long /*int*/ id, long /*int*/ sel, NSRect rect) { if (!isDrawing()) return; Display display = this.display; NSView view = new NSView(id); @@ -748,17 +748,17 @@ void drawRect (int /*long*/ id, int /*long*/ sel, NSRect rect) { display.isPainting.removeObjectIdenticalTo(view); } -void _drawThemeProgressArea (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void _drawThemeProgressArea (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, arg0); } -void drawWidget (int /*long*/ id, NSGraphicsContext context, NSRect rect) { +void drawWidget (long /*int*/ id, NSGraphicsContext context, NSRect rect) { } -int /*long*/ imageView () { +long /*int*/ imageView () { return 0; } @@ -766,7 +766,7 @@ void redrawWidget (NSView view, boolean children) { view.setNeedsDisplay(true); } -void redrawWidget (NSView view, int /*long*/ x, int /*long*/ y, int /*long*/ width, int /*long*/ height, boolean children) { +void redrawWidget (NSView view, long /*int*/ x, long /*int*/ y, long /*int*/ width, long /*int*/ height, boolean children) { NSRect rect = new NSRect(); rect.x = x; rect.y = y; @@ -779,14 +779,14 @@ void error (int code) { SWT.error(code); } -void expandItem_expandChildren (int /*long*/ id, int /*long*/ sel, int /*long*/ item, boolean children) { +void expandItem_expandChildren (long /*int*/ id, long /*int*/ sel, long /*int*/ item, boolean children) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, item, children); } -NSRect expansionFrameWithFrame_inView(int /*long*/ id, int /*long*/ sel, NSRect cellRect, int /*long*/ view) { +NSRect expansionFrameWithFrame_inView(long /*int*/ id, long /*int*/ sel, NSRect cellRect, long /*int*/ view) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -799,7 +799,7 @@ boolean filters (int eventType) { return display.filters (eventType); } -NSRect firstRectForCharacterRange(int /*long*/ id, int /*long*/ sel, int /*long*/ range) { +NSRect firstRectForCharacterRange(long /*int*/ id, long /*int*/ sel, long /*int*/ range) { return new NSRect (); } @@ -967,28 +967,28 @@ public int getStyle () { return style; } -boolean hasMarkedText (int /*long*/ id, int /*long*/ sel) { +boolean hasMarkedText (long /*int*/ id, long /*int*/ sel) { return false; } -NSRect headerRectOfColumn (int /*long*/ id, int /*long*/ sel, int /*long*/ column) { +NSRect headerRectOfColumn (long /*int*/ id, long /*int*/ sel, long /*int*/ column) { return callSuperRect(id, sel, column); } -void helpRequested(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void helpRequested(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { } -void highlightSelectionInClipRect(int /*long*/ id, int /*long*/ sel, int /*long*/ rect) { +void highlightSelectionInClipRect(long /*int*/ id, long /*int*/ sel, long /*int*/ rect) { } -int /*long*/ hitTest (int /*long*/ id, int /*long*/ sel, NSPoint point) { +long /*int*/ hitTest (long /*int*/ id, long /*int*/ sel, NSPoint point) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, point); } -int /*long*/ hitTestForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event, NSRect rect, int /*long*/ controlView) { +long /*int*/ hitTestForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event, NSRect rect, long /*int*/ controlView) { return 0; } @@ -997,15 +997,15 @@ boolean hooks (int eventType) { return eventTable.hooks (eventType); } -int /*long*/ image (int /*long*/ id, int /*long*/ sel) { +long /*int*/ image (long /*int*/ id, long /*int*/ sel) { return 0; } -NSRect imageRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSRect imageRectForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { return new NSRect(); } -boolean insertText (int /*long*/ id, int /*long*/ sel, int /*long*/ string) { +boolean insertText (long /*int*/ id, long /*int*/ sel, long /*int*/ string) { callSuper (id, sel, string); return true; } @@ -1033,7 +1033,7 @@ boolean isDrawing () { return true; } -boolean isFlipped(int /*long*/ id, int /*long*/ sel) { +boolean isFlipped(long /*int*/ id, long /*int*/ sel) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -1061,7 +1061,7 @@ public boolean isListening (int eventType) { return hooks (eventType); } -boolean isOpaque(int /*long*/ id, int /*long*/ sel) { +boolean isOpaque(long /*int*/ id, long /*int*/ sel) { return false; } @@ -1073,178 +1073,178 @@ boolean isValidThread () { return getDisplay ().isValidThread (); } -void flagsChanged (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void flagsChanged (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper (id, sel, theEvent); } -void keyDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyDown (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { superKeyDown(id, sel, theEvent); } -void keyUp (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void keyUp (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { superKeyUp(id, sel, theEvent); } -void mouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { mouseDownSuper(id, sel, theEvent); } -boolean mouseDownCanMoveWindow(int /*long*/ id, int /*long*/ sel) { +boolean mouseDownCanMoveWindow(long /*int*/ id, long /*int*/ sel) { return callSuperBoolean(id, sel); } -void mouseDownSuper(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDownSuper(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void mouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void mouseMoved(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseMoved(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void mouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void mouseEntered(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseEntered(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void mouseExited(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void mouseExited(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void cursorUpdate(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void cursorUpdate(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void rightMouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void rightMouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void rightMouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void rightMouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void otherMouseDown(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseDown(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void otherMouseUp(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseUp(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -void otherMouseDragged(int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void otherMouseDragged(long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -boolean shouldDelayWindowOrderingForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +boolean shouldDelayWindowOrderingForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, theEvent) != 0; } -boolean menuHasKeyEquivalent_forEvent_target_action(int /*long*/ id, int /*long*/ sel, int /*long*/ menu, int /*long*/ event, int /*long*/ target, int /*long*/ action) { +boolean menuHasKeyEquivalent_forEvent_target_action(long /*int*/ id, long /*int*/ sel, long /*int*/ menu, long /*int*/ event, long /*int*/ target, long /*int*/ action) { return true; } -int /*long*/ menuForEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +long /*int*/ menuForEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); return OS.objc_msgSendSuper(super_struct, sel, theEvent); } -void menuNeedsUpdate(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuNeedsUpdate(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { } -boolean makeFirstResponder(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +boolean makeFirstResponder(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { return callSuperBoolean(id, sel, notification); } -NSRange markedRange (int /*long*/ id, int /*long*/ sel) { +NSRange markedRange (long /*int*/ id, long /*int*/ sel) { return new NSRange (); } -void menu_willHighlightItem(int /*long*/ id, int /*long*/ sel, int /*long*/ menu, int /*long*/ item) { +void menu_willHighlightItem(long /*int*/ id, long /*int*/ sel, long /*int*/ menu, long /*int*/ item) { } -void menuDidClose(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuDidClose(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { } -void menuWillOpen(int /*long*/ id, int /*long*/ sel, int /*long*/ menu) { +void menuWillOpen(long /*int*/ id, long /*int*/ sel, long /*int*/ menu) { } -void noResponderFor(int /*long*/ id, int /*long*/ sel, int /*long*/ selector) { +void noResponderFor(long /*int*/ id, long /*int*/ sel, long /*int*/ selector) { callSuper(id, sel, selector); } -int /*long*/ numberOfRowsInTableView(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView) { +long /*int*/ numberOfRowsInTableView(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView) { return 0; } -int /*long*/ outlineView_child_ofItem(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ index, int /*long*/ item) { +long /*int*/ outlineView_child_ofItem(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ index, long /*int*/ item) { return 0; } -void outlineView_didClickTableColumn(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ tableColumn) { +void outlineView_didClickTableColumn(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ tableColumn) { } -int /*long*/ outlineView_objectValueForTableColumn_byItem(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ tableColumn, int /*long*/ item) { +long /*int*/ outlineView_objectValueForTableColumn_byItem(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ tableColumn, long /*int*/ item) { return 0; } -boolean outlineView_isItemExpandable(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ item) { +boolean outlineView_isItemExpandable(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ item) { return false; } -int /*long*/ outlineView_numberOfChildrenOfItem(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ item) { +long /*int*/ outlineView_numberOfChildrenOfItem(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ item) { return 0; } -boolean outlineView_shouldExpandItem_item(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ item) { +boolean outlineView_shouldExpandItem_item(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ item) { return true; } -boolean outlineView_shouldReorderColumn_toColumn(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ columnIndex, int /*long*/ newColumnIndex) { +boolean outlineView_shouldReorderColumn_toColumn(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ columnIndex, long /*int*/ newColumnIndex) { return true; } -boolean outlineView_shouldEditTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ aTableColumn, int /*long*/ item) { +boolean outlineView_shouldEditTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ aTableColumn, long /*int*/ item) { return false; } -boolean outlineView_shouldTrackCell_forTableColumn_item(int /*long*/ id, int /*long*/ sel, int /*long*/ table, int /*long*/ cell, int /*long*/ tableColumn, int /*long*/ item) { +boolean outlineView_shouldTrackCell_forTableColumn_item(long /*int*/ id, long /*int*/ sel, long /*int*/ table, long /*int*/ cell, long /*int*/ tableColumn, long /*int*/ item) { return true; } -void outlineView_willDisplayCell_forTableColumn_item(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ cell, int /*long*/ tableColumn, int /*long*/ item) { +void outlineView_willDisplayCell_forTableColumn_item(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ cell, long /*int*/ tableColumn, long /*int*/ item) { } -void outlineViewColumnDidMove (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void outlineViewColumnDidMove (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { } -void outlineViewColumnDidResize (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void outlineViewColumnDidResize (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { } -void outlineViewSelectionDidChange(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void outlineViewSelectionDidChange(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void outlineViewSelectionIsChanging(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void outlineViewSelectionIsChanging(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void outlineView_setObjectValue_forTableColumn_byItem(int /*long*/ id, int /*long*/ sel, int /*long*/ outlineView, int /*long*/ object, int /*long*/ tableColumn, int /*long*/ item) { +void outlineView_setObjectValue_forTableColumn_byItem(long /*int*/ id, long /*int*/ sel, long /*int*/ outlineView, long /*int*/ object, long /*int*/ tableColumn, long /*int*/ item) { } -boolean outlineView_writeItems_toPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2) { +boolean outlineView_writeItems_toPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) { return false; } @@ -1275,11 +1275,11 @@ public void notifyListeners (int eventType, Event event) { sendEvent (eventType, event); } -void pageDown (int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void pageDown (long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { callSuper(id, sel, sender); } -void pageUp (int /*long*/ id, int /*long*/ sel, int /*long*/ sender) { +void pageUp (long /*int*/ id, long /*int*/ sel, long /*int*/ sender) { callSuper(id, sel, sender); } @@ -1291,7 +1291,7 @@ void postEvent (int eventType, Event event) { sendEvent (eventType, event, false); } -void reflectScrolledClipView (int /*long*/ id, int /*long*/ sel, int /*long*/ aClipView) { +void reflectScrolledClipView (long /*int*/ id, long /*int*/ sel, long /*int*/ aClipView) { callSuper (id, sel, aClipView); } @@ -1425,33 +1425,33 @@ public void removeDisposeListener (DisposeListener listener) { eventTable.unhook (SWT.Dispose, listener); } -void scrollClipViewToPoint (int /*long*/ id, int /*long*/ sel, int /*long*/ clipView, NSPoint point) { +void scrollClipViewToPoint (long /*int*/ id, long /*int*/ sel, long /*int*/ clipView, NSPoint point) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, clipView, point); } -void selectRowIndexes_byExtendingSelection (int /*long*/ id, int /*long*/ sel, int /*long*/ indexes, boolean extend) { +void selectRowIndexes_byExtendingSelection (long /*int*/ id, long /*int*/ sel, long /*int*/ indexes, boolean extend) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, indexes, extend); } -void scrollWheel (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void scrollWheel (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper(id, sel, theEvent); } -NSRange selectedRange (int /*long*/ id, int /*long*/ sel) { +NSRange selectedRange (long /*int*/ id, long /*int*/ sel) { return new NSRange (); } -int /*long*/ nextValidKeyView (int /*long*/ id, int /*long*/ sel) { +long /*int*/ nextValidKeyView (long /*int*/ id, long /*int*/ sel) { return callSuperObject(id, sel); } -int /*long*/ previousValidKeyView (int /*long*/ id, int /*long*/ sel) { +long /*int*/ previousValidKeyView (long /*int*/ id, long /*int*/ sel) { return callSuperObject(id, sel); } @@ -1653,21 +1653,21 @@ void setOpenGLContext(Object value) { void setOrientation () { } -void setFrameOrigin (int /*long*/ id, int /*long*/ sel, NSPoint point) { +void setFrameOrigin (long /*int*/ id, long /*int*/ sel, NSPoint point) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, point); } -void setFrameSize (int /*long*/ id, int /*long*/ sel, NSSize size) { +void setFrameSize (long /*int*/ id, long /*int*/ sel, NSSize size) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); OS.objc_msgSendSuper(super_struct, sel, size); } -void setImage (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void setImage (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { } boolean setInputState (Event event, NSEvent nsEvent, int type) { @@ -1675,7 +1675,7 @@ boolean setInputState (Event event, NSEvent nsEvent, int type) { nsEvent = NSApplication.sharedApplication().currentEvent(); if (nsEvent == null) return true; } - int /*long*/ modifierFlags = nsEvent.modifierFlags(); + long /*int*/ modifierFlags = nsEvent.modifierFlags(); if ((modifierFlags & OS.NSAlternateKeyMask) != 0) event.stateMask |= SWT.ALT; if ((modifierFlags & OS.NSShiftKeyMask) != 0) event.stateMask |= SWT.SHIFT; if ((modifierFlags & OS.NSControlKeyMask) != 0) event.stateMask |= SWT.CONTROL; @@ -1748,15 +1748,15 @@ boolean setKeyState (Event event, int type, NSEvent nsEvent) { if (chars != null && chars.length() > 0) event.character = (char)chars.characterAtIndex (0); } if (event.keyCode == 0) { - int /*long*/ uchrPtr = 0; - int /*long*/ currentKbd = OS.TISCopyCurrentKeyboardInputSource(); - int /*long*/ uchrCFData = OS.TISGetInputSourceProperty(currentKbd, OS.kTISPropertyUnicodeKeyLayoutData()); + long /*int*/ uchrPtr = 0; + long /*int*/ currentKbd = OS.TISCopyCurrentKeyboardInputSource(); + long /*int*/ uchrCFData = OS.TISGetInputSourceProperty(currentKbd, OS.kTISPropertyUnicodeKeyLayoutData()); if (uchrCFData != 0) { uchrPtr = OS.CFDataGetBytePtr(uchrCFData); if (uchrPtr != 0 && OS.CFDataGetLength(uchrCFData) > 0) { - int /*long*/ cgEvent = nsEvent.CGEvent(); + long /*int*/ cgEvent = nsEvent.CGEvent(); long keyboardType = OS.CGEventGetIntegerValueField(cgEvent, OS.kCGKeyboardEventKeyboardType); int maxStringLength = 256; @@ -1825,11 +1825,11 @@ void setLocationMask (Event event, NSEvent nsEvent) { } } -boolean setMarkedText_selectedRange (int /*long*/ id, int /*long*/ sel, int /*long*/ string, int /*long*/ range) { +boolean setMarkedText_selectedRange (long /*int*/ id, long /*int*/ sel, long /*int*/ string, long /*int*/ range) { return true; } -void setNeedsDisplay (int /*long*/ id, int /*long*/ sel, boolean flag) { +void setNeedsDisplay (long /*int*/ id, long /*int*/ sel, boolean flag) { if (flag && !isDrawing()) return; NSView view = new NSView(id); if (flag && display.isPainting.containsObject(view)) { @@ -1847,7 +1847,7 @@ void setNeedsDisplay (int /*long*/ id, int /*long*/ sel, boolean flag) { OS.objc_msgSendSuper(super_struct, sel, flag); } -void setNeedsDisplayInRect (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void setNeedsDisplayInRect (long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { if (!isDrawing()) return; NSRect rect = new NSRect(); OS.memmove(rect, arg0, NSRect.sizeof); @@ -1868,14 +1868,14 @@ void setNeedsDisplayInRect (int /*long*/ id, int /*long*/ sel, int /*long*/ arg0 OS.objc_msgSendSuper(super_struct, sel, rect); } -void setObjectValue(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void setObjectValue(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { callSuper(id, sel, arg0); } -void setShouldExpandItem(int /*long*/ id, int /*long*/ sel, boolean shouldExpand) { +void setShouldExpandItem(long /*int*/ id, long /*int*/ sel, boolean shouldExpand) { } -void setShouldScrollClipView(int /*long*/ id, int /*long*/ sel, boolean shouldScroll) { +void setShouldScrollClipView(long /*int*/ id, long /*int*/ sel, boolean shouldScroll) { } boolean setTabGroupFocus () { @@ -1886,11 +1886,11 @@ boolean setTabItemFocus () { return false; } -boolean shouldChangeTextInRange_replacementString(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1) { +boolean shouldChangeTextInRange_replacementString(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1) { return true; } -NSSize sizeOfLabel(int /*long*/ id, int /*long*/ sel, boolean shouldTruncateLabel) { +NSSize sizeOfLabel(long /*int*/ id, long /*int*/ sel, boolean shouldTruncateLabel) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -1899,71 +1899,71 @@ NSSize sizeOfLabel(int /*long*/ id, int /*long*/ sel, boolean shouldTruncateLabe return result; } -void superKeyDown (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void superKeyDown (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper (id, sel, theEvent); } -void superKeyUp (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) { +void superKeyUp (long /*int*/ id, long /*int*/ sel, long /*int*/ theEvent) { callSuper (id, sel, theEvent); } -void tableViewColumnDidMove (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewColumnDidMove (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { } -void tableViewColumnDidResize (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewColumnDidResize (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { } -void tableViewSelectionDidChange (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewSelectionDidChange (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { } -void tableViewSelectionIsChanging (int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void tableViewSelectionIsChanging (long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { } -void tableView_didClickTableColumn(int /*long*/ id, int /*long*/ sel, int /*long*/ tableView, int /*long*/ tableColumn) { +void tableView_didClickTableColumn(long /*int*/ id, long /*int*/ sel, long /*int*/ tableView, long /*int*/ tableColumn) { } -int /*long*/ tableView_objectValueForTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ aTableColumn, int /*long*/ rowIndex) { +long /*int*/ tableView_objectValueForTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ aTableColumn, long /*int*/ rowIndex) { return 0; } -boolean tableView_shouldSelectRow(int /*long*/ id, int /*long*/ sel, int /*long*/ tableView, int /*long*/ index) { +boolean tableView_shouldSelectRow(long /*int*/ id, long /*int*/ sel, long /*int*/ tableView, long /*int*/ index) { return true; } -void tableView_setObjectValue_forTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ anObject, int /*long*/ aTableColumn, int /*long*/ rowIndex) { +void tableView_setObjectValue_forTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ anObject, long /*int*/ aTableColumn, long /*int*/ rowIndex) { } -boolean tableView_shouldReorderColumn_toColumn(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ columnIndex, int /*long*/ newColumnIndex) { +boolean tableView_shouldReorderColumn_toColumn(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ columnIndex, long /*int*/ newColumnIndex) { return true; } -boolean tableView_shouldEditTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ aTableColumn, int /*long*/ rowIndex) { +boolean tableView_shouldEditTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ aTableColumn, long /*int*/ rowIndex) { return false; } -boolean tableView_shouldTrackCell_forTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ table, int /*long*/ cell, /*long*/ int /*long*/ tableColumn, int /*long*/ rowIndex) { +boolean tableView_shouldTrackCell_forTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ table, long /*int*/ cell, /*long*/ long /*int*/ tableColumn, long /*int*/ rowIndex) { return true; } -void tableView_willDisplayCell_forTableColumn_row(int /*long*/ id, int /*long*/ sel, int /*long*/ aTableView, int /*long*/ aCell, int /*long*/ aTableColumn, int /*long*/ rowIndex) { +void tableView_willDisplayCell_forTableColumn_row(long /*int*/ id, long /*int*/ sel, long /*int*/ aTableView, long /*int*/ aCell, long /*int*/ aTableColumn, long /*int*/ rowIndex) { } -void textViewDidChangeSelection(int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textViewDidChangeSelection(long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { } -void textDidChange(int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textDidChange(long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { callSuper (id, sel, aNotification); } -void textDidEndEditing(int /*long*/ id, int /*long*/ sel, int /*long*/ aNotification) { +void textDidEndEditing(long /*int*/ id, long /*int*/ sel, long /*int*/ aNotification) { callSuper(id, sel, aNotification); } -NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange(int /*long*/ id, int /*long*/ sel, int /*long*/ aTextView, int /*long*/ oldSelectedCharRange, int /*long*/ newSelectedCharRange) { +NSRange textView_willChangeSelectionFromCharacterRange_toCharacterRange(long /*int*/ id, long /*int*/ sel, long /*int*/ aTextView, long /*int*/ oldSelectedCharRange, long /*int*/ newSelectedCharRange) { return new NSRange(); } -NSRect titleRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) { +NSRect titleRectForBounds (long /*int*/ id, long /*int*/ sel, NSRect cellFrame) { objc_super super_struct = new objc_super(); super_struct.receiver = id; super_struct.super_class = OS.objc_msgSend(id, OS.sel_superclass); @@ -1972,19 +1972,19 @@ NSRect titleRectForBounds (int /*long*/ id, int /*long*/ sel, NSRect cellFrame) return result; } -int /*long*/ toolbar_itemForItemIdentifier_willBeInsertedIntoToolbar(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar, int /*long*/ itemID, boolean flag) { +long /*int*/ toolbar_itemForItemIdentifier_willBeInsertedIntoToolbar(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar, long /*int*/ itemID, boolean flag) { return 0; } -int /*long*/ toolbarAllowedItemIdentifiers(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar) { +long /*int*/ toolbarAllowedItemIdentifiers(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar) { return 0; } -int /*long*/ toolbarDefaultItemIdentifiers(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar) { +long /*int*/ toolbarDefaultItemIdentifiers(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar) { return 0; } -int /*long*/ toolbarSelectableItemIdentifiers(int /*long*/ id, int /*long*/ sel, int /*long*/ toolbar) { +long /*int*/ toolbarSelectableItemIdentifiers(long /*int*/ id, long /*int*/ sel, long /*int*/ toolbar) { return 0; } String tooltipText () { @@ -2006,127 +2006,127 @@ public String toString () { return getName () + " {" + string + "}"; } -void touchesBeganWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesBeganWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void touchesCancelledWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesCancelledWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void touchesEndedWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesEndedWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void touchesMovedWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void touchesMovedWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void beginGestureWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void beginGestureWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void endGestureWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void endGestureWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void magnifyWithEvent (int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void magnifyWithEvent (long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void rotateWithEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void rotateWithEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void swipeWithEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void swipeWithEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -void resetCursorRects (int /*long*/ id, int /*long*/ sel) { +void resetCursorRects (long /*int*/ id, long /*int*/ sel) { callSuper (id, sel); } -void updateTrackingAreas (int /*long*/ id, int /*long*/ sel) { +void updateTrackingAreas (long /*int*/ id, long /*int*/ sel) { callSuper (id, sel); } -int /*long*/ validAttributesForMarkedText (int /*long*/ id, int /*long*/ sel) { +long /*int*/ validAttributesForMarkedText (long /*int*/ id, long /*int*/ sel) { return 0; } -void tabView_didSelectTabViewItem(int /*long*/ id, int /*long*/ sel, int /*long*/ tabView, int /*long*/ tabViewItem) { +void tabView_didSelectTabViewItem(long /*int*/ id, long /*int*/ sel, long /*int*/ tabView, long /*int*/ tabViewItem) { } -void tabView_willSelectTabViewItem(int /*long*/ id, int /*long*/ sel, int /*long*/ tabView, int /*long*/ tabViewItem) { +void tabView_willSelectTabViewItem(long /*int*/ id, long /*int*/ sel, long /*int*/ tabView, long /*int*/ tabViewItem) { } -boolean tableView_writeRowsWithIndexes_toPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0, int /*long*/ arg1, int /*long*/ arg2) { +boolean tableView_writeRowsWithIndexes_toPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) { return false; } -boolean validateMenuItem(int /*long*/ id, int /*long*/ sel, int /*long*/ menuItem) { +boolean validateMenuItem(long /*int*/ id, long /*int*/ sel, long /*int*/ menuItem) { return true; } -int /*long*/ view_stringForToolTip_point_userData (int /*long*/ id, int /*long*/ sel, int /*long*/ view, int /*long*/ tag, int /*long*/ point, int /*long*/ userData) { +long /*int*/ view_stringForToolTip_point_userData (long /*int*/ id, long /*int*/ sel, long /*int*/ view, long /*int*/ tag, long /*int*/ point, long /*int*/ userData) { return 0; } -void viewDidMoveToWindow(int /*long*/ id, int /*long*/ sel) { +void viewDidMoveToWindow(long /*int*/ id, long /*int*/ sel) { } -void viewWillMoveToWindow(int /*long*/ id, int /*long*/ sel, int /*long*/ arg0) { +void viewWillMoveToWindow(long /*int*/ id, long /*int*/ sel, long /*int*/ arg0) { } -void windowDidMove(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidMove(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void windowDidResize(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidResize(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void windowDidResignKey(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidResignKey(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void windowDidBecomeKey(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidBecomeKey(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void windowDidMiniturize(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidMiniturize(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void windowDidDeminiturize(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowDidDeminiturize(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -void windowSendEvent(int /*long*/ id, int /*long*/ sel, int /*long*/ event) { +void windowSendEvent(long /*int*/ id, long /*int*/ sel, long /*int*/ event) { callSuper(id, sel, event); } -boolean windowShouldClose(int /*long*/ id, int /*long*/ sel, int /*long*/ window) { +boolean windowShouldClose(long /*int*/ id, long /*int*/ sel, long /*int*/ window) { return false; } -void windowWillClose(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void windowWillClose(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -int /*long*/ nextState(int /*long*/ id, int /*long*/ sel) { +long /*int*/ nextState(long /*int*/ id, long /*int*/ sel) { return callSuperObject(id, sel); } -void updateOpenGLContext(int /*long*/ id, int /*long*/ sel, int /*long*/ notification) { +void updateOpenGLContext(long /*int*/ id, long /*int*/ sel, long /*int*/ notification) { } -boolean shouldDrawInsertionPoint(int /*long*/ id, int /*long*/ sel) { +boolean shouldDrawInsertionPoint(long /*int*/ id, long /*int*/ sel) { return callSuperBoolean(id, sel); } -boolean readSelectionFromPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ pasteboard) { +boolean readSelectionFromPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ pasteboard) { return false; } -int /*long*/ validRequestorForSendType(int /*long*/ id, int /*long*/ sel, int /*long*/ sendType, int /*long*/ returnType) { +long /*int*/ validRequestorForSendType(long /*int*/ id, long /*int*/ sel, long /*int*/ sendType, long /*int*/ returnType) { return callSuperObject(id, sel, sendType, returnType); } -boolean writeSelectionToPasteboard(int /*long*/ id, int /*long*/ sel, int /*long*/ pasteboard, int /*long*/ types) { +boolean writeSelectionToPasteboard(long /*int*/ id, long /*int*/ sel, long /*int*/ pasteboard, long /*int*/ types) { return false; } |