Finished off backend indepenend dragging.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@19546 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Fred Kiefer 2004-06-18 23:49:40 +00:00
parent 36e5bff453
commit c5023b12e4
5 changed files with 33 additions and 3 deletions

View file

@ -1,3 +1,14 @@
2004-06-19 Fred Kiefer <FredKiefer@gmx.de>
* Headers/Additions/GNUstepGUI/GSDisplayServer.h: Added new method
(-findWindowAt:windowRef:excluding:).
* Source/GSDisplayServer.m: Implemented (-dragInfo) with
GSDragView.
* Source/GNUmakefile: Added GSDragView.h.
* Source/GSDragView.m: Implemented
(-_windowAcceptingDnDunder:windowRef:) with new GSDisplayServer
method.
2004-06-17 Fred Kiefer <FredKiefer@gmx.de>
* Source/NSComboBoxCell.m: buttonCellFrameFromRect(),

View file

@ -82,6 +82,10 @@ APPKIT_EXPORT NSString * GSScreenNumber;
- (id <NSDraggingInfo>) dragInfo;
- (BOOL) slideImage: (NSImage*)image from: (NSPoint)from to: (NSPoint)to;
- (void) restrictWindow: (int)win toImage: (NSImage*)image;
- (int) findWindowAt: (NSPoint)screenLocation
windowRef: (int*)windowRef
excluding: (int)win;
/* Screen information */
- (NSSize) resolutionForScreen: (int)screen;

View file

@ -354,6 +354,7 @@ GSHorizontalTypesetter.h \
GSToolbar.h \
GSToolbarView.h \
GSNibCompatibility.h \
GSDragView.h \
GSTitleView.h
libgnustep-gui_HEADER_FILES = ${GUI_HEADERS}

View file

@ -35,6 +35,7 @@
#include "AppKit/NSImage.h"
#include "AppKit/NSWindow.h"
#include "GNUstepGUI/GSDisplayServer.h"
#include "GNUstepGUI/GSDragView.h"
#include "GSSlideView.h"
@ -385,8 +386,7 @@ GSCurrentServer(void)
protocol. */
- (id <NSDraggingInfo>) dragInfo
{
[self subclassResponsibility: _cmd];
return nil;
return [GSDragView sharedDragView];
}
- (BOOL) slideImage: (NSImage*)image from: (NSPoint)from to: (NSPoint)to
@ -399,6 +399,14 @@ GSCurrentServer(void)
[self subclassResponsibility: _cmd];
}
- (int) findWindowAt: (NSPoint)screenLocation
windowRef: (int*)windowRef
excluding: (int)win
{
[self subclassResponsibility: _cmd];
return 0;
}
/* Screen information */
/** Retuns the resolution, in points, for the indicated screen of the
display. */

View file

@ -957,8 +957,14 @@ static GSDragView *sharedDragView = nil;
- (NSWindow*) _windowAcceptingDnDunder: (NSPoint)mouseLocation
windowRef: (int*)mouseWindowRef
{
int win;
*mouseWindowRef = 0;
return nil;
win = [GSServerForWindow(_window) findWindowAt: mouseLocation
windowRef: mouseWindowRef
excluding: [_window windowNumber]];
return GSWindowWithNumber(win);
}
@end