mirror of
https://github.com/gnustep/libs-back.git
synced 2025-02-23 11:51:27 +00:00
Update to take advantage of new base library functionality.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@21924 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
2fc83c755f
commit
22e9233bd6
2 changed files with 30 additions and 6 deletions
|
@ -1,7 +1,9 @@
|
|||
2005-10-30 Richard Frith-Macdonald <rfm@gnu.org>
|
||||
|
||||
* Source/win32/Win33Server.m: synchronize defaults so settings are
|
||||
* Source/win32/WIN33Server.m: synchronize defaults so settings are
|
||||
not lost. Tidy a lot of stuff to conform to coding standards.
|
||||
Update event handling code to use ET_WINMSG rather than less versatile
|
||||
deprecated API.
|
||||
|
||||
2005-10-23 Adam Fedor <fedor@gnu.org>
|
||||
|
||||
|
|
|
@ -110,6 +110,20 @@ LRESULT CALLBACK MainWndProc(HWND hwnd, UINT uMsg,
|
|||
extra: (void*)extra
|
||||
forMode: (NSString*)mode
|
||||
{
|
||||
if (type == ET_WINMSG)
|
||||
{
|
||||
MSG *m = (MSG*)extra;
|
||||
|
||||
if (m->message == WM_QUIT)
|
||||
{
|
||||
// Exit the program
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
DispatchMessage(m);
|
||||
}
|
||||
}
|
||||
if (mode != nil)
|
||||
[self callback: mode];
|
||||
}
|
||||
|
@ -212,6 +226,8 @@ printf("\n\n##############################################################\n");
|
|||
|
||||
- (void) setupRunLoopInputSourcesForMode: (NSString*)mode
|
||||
{
|
||||
NSRunLoop *currentRunLoop = [NSRunLoop currentRunLoop];
|
||||
|
||||
#ifdef __debugServer__
|
||||
printf("\n\n##############################################################\n");
|
||||
printf("##- (void) setupRunLoopInputSourcesForMode: (NSString*)mode #######\n");
|
||||
|
@ -219,7 +235,6 @@ printf("\n\n##############################################################\n");
|
|||
#endif
|
||||
|
||||
#ifdef __CYGWIN__
|
||||
NSRunLoop *currentRunLoop = [NSRunLoop currentRunLoop];
|
||||
int fdMessageQueue;
|
||||
#define WIN_MSG_QUEUE_FNAME "/dev/windows"
|
||||
|
||||
|
@ -243,11 +258,18 @@ printf("\n\n##############################################################\n");
|
|||
selector: @selector(callback:)
|
||||
userInfo: nil
|
||||
repeats: YES];
|
||||
[[NSRunLoop currentRunLoop] addTimer: timer forMode: mode];
|
||||
[currentRunLoop addTimer: timer forMode: mode];
|
||||
#else
|
||||
[[NSRunLoop currentRunLoop] addMsgTarget: self
|
||||
|
||||
/* OBSOLETE
|
||||
[currentRunLoop addMsgTarget: self
|
||||
withMethod: @selector(callback:)
|
||||
forMode: mode];
|
||||
*/
|
||||
[currentRunLoop addEvent: (void*)0
|
||||
type: ET_WINMSG
|
||||
watcher: (id<RunLoopEvents>)self
|
||||
forMode: mode];
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue