View | Details | Raw Unified | Return to bug 188320
Collapse All | Expand All

(-)Eclipse SWT/gtk/org/eclipse/swt/widgets/Display.java (-1 / +8 lines)
Lines 102-107 Link Here
102
	int /*long*/ fds;
102
	int /*long*/ fds;
103
	int allocated_nfds;
103
	int allocated_nfds;
104
	boolean wake;
104
	boolean wake;
105
	Object wakeLock = new Object ();
105
	int [] max_priority = new int [1], timeout = new int [1];
106
	int [] max_priority = new int [1], timeout = new int [1];
106
	Callback eventCallback, filterCallback;
107
	Callback eventCallback, filterCallback;
107
	int /*long*/ eventProc, filterProc, windowProc2, windowProc3, windowProc4, windowProc5;
108
	int /*long*/ eventProc, filterProc, windowProc2, windowProc3, windowProc4, windowProc5;
Lines 3653-3658 Link Here
3653
	max_priority [0] = timeout [0] = 0;
3654
	max_priority [0] = timeout [0] = 0;
3654
	int /*long*/ context = OS.g_main_context_default ();
3655
	int /*long*/ context = OS.g_main_context_default ();
3655
	boolean result = false;
3656
	boolean result = false;
3657
	boolean wake = false;
3656
	do {
3658
	do {
3657
		if (OS.g_main_context_acquire (context)) {
3659
		if (OS.g_main_context_acquire (context)) {
3658
			result = OS.g_main_context_prepare (context, max_priority);
3660
			result = OS.g_main_context_prepare (context, max_priority);
Lines 3688-3693 Link Here
3688
			OS.g_main_context_check (context, max_priority [0], fds, nfds);
3690
			OS.g_main_context_check (context, max_priority [0], fds, nfds);
3689
			OS.g_main_context_release (context);
3691
			OS.g_main_context_release (context);
3690
		}
3692
		}
3693
		synchronized (wakeLock) {
3694
			wake = this.wake;
3695
		}
3691
	} while (!result && getMessageCount () == 0 && !wake);
3696
	} while (!result && getMessageCount () == 0 && !wake);
3692
	wake = false;
3697
	wake = false;
3693
	return true;
3698
	return true;
Lines 3947-3953 Link Here
3947
3952
3948
void wakeThread () {
3953
void wakeThread () {
3949
	OS.g_main_context_wakeup (0);
3954
	OS.g_main_context_wakeup (0);
3950
	wake = true;
3955
	synchronized (wakeLock) {
3956
		wake = true;
3957
	}
3951
}
3958
}
3952
3959
3953
static char wcsToMbcs (char ch) {
3960
static char wcsToMbcs (char ch) {

Return to bug 188320