提交 5f7dd87a 编写于 作者: D dcherepanov

6603010: Out-of-process Java Plug-In non-functional or barely functional on X11 platforms

Summary: AWT XEmbed shouldn't use _SUN_XEMBED_START message
Reviewed-by: art, son
上级 86c5b5ee
...@@ -647,12 +647,6 @@ public class XEmbedCanvasPeer extends XCanvasPeer implements WindowFocusListener ...@@ -647,12 +647,6 @@ public class XEmbedCanvasPeer extends XCanvasPeer implements WindowFocusListener
} }
if (isXEmbedActive()) { if (isXEmbedActive()) {
switch ((int)msg.get_data(1)) { switch ((int)msg.get_data(1)) {
case _SUN_XEMBED_START:
// Child has finished initialization and waits for notify
xembed.processXEmbedInfo();
notifyChildEmbedded();
break;
case XEMBED_REQUEST_FOCUS: case XEMBED_REQUEST_FOCUS:
requestXEmbedFocus(); requestXEmbedFocus();
break; break;
......
...@@ -74,7 +74,6 @@ public class XEmbedClientHelper extends XEmbedHelper implements XEventDispatcher ...@@ -74,7 +74,6 @@ public class XEmbedClientHelper extends XEmbedHelper implements XEventDispatcher
XToolkit.awtUnlock(); XToolkit.awtUnlock();
} }
} }
notifyReady();
} }
void handleClientMessage(XEvent xev) { void handleClientMessage(XEvent xev) {
...@@ -84,7 +83,6 @@ public class XEmbedClientHelper extends XEmbedHelper implements XEventDispatcher ...@@ -84,7 +83,6 @@ public class XEmbedClientHelper extends XEmbedHelper implements XEventDispatcher
if (xembedLog.isLoggable(Level.FINE)) xembedLog.fine("Embedded message: " + msgidToString((int)msg.get_data(1))); if (xembedLog.isLoggable(Level.FINE)) xembedLog.fine("Embedded message: " + msgidToString((int)msg.get_data(1)));
switch ((int)msg.get_data(1)) { switch ((int)msg.get_data(1)) {
case XEMBED_EMBEDDED_NOTIFY: // Notification about embedding protocol start case XEMBED_EMBEDDED_NOTIFY: // Notification about embedding protocol start
// NOTE: May be called two times because we send _SUN_XEMBED_START
active = true; active = true;
server = getEmbedder(embedded, msg); server = getEmbedder(embedded, msg);
// Check if window is reparented. If not - it was created with // Check if window is reparented. If not - it was created with
...@@ -223,13 +221,4 @@ public class XEmbedClientHelper extends XEmbedHelper implements XEventDispatcher ...@@ -223,13 +221,4 @@ public class XEmbedClientHelper extends XEmbedHelper implements XEventDispatcher
long getX11Mods(AWTKeyStroke stroke) { long getX11Mods(AWTKeyStroke stroke) {
return XWindow.getXModifiers(stroke); return XWindow.getXModifiers(stroke);
} }
void notifyReady() {
long wnd = server;
if (wnd == 0) {
// Server is still 0, get the parent
wnd = embedded.getParentWindowHandle();
}
sendMessage(wnd, _SUN_XEMBED_START);
}
} }
...@@ -58,7 +58,6 @@ public class XEmbedHelper { ...@@ -58,7 +58,6 @@ public class XEmbedHelper {
final static int XEMBED_REGISTER_ACCELERATOR = 12; final static int XEMBED_REGISTER_ACCELERATOR = 12;
final static int XEMBED_UNREGISTER_ACCELERATOR= 13; final static int XEMBED_UNREGISTER_ACCELERATOR= 13;
final static int XEMBED_ACTIVATE_ACCELERATOR = 14; final static int XEMBED_ACTIVATE_ACCELERATOR = 14;
final static int _SUN_XEMBED_START = 1119;
final static int NON_STANDARD_XEMBED_GTK_GRAB_KEY = 108; final static int NON_STANDARD_XEMBED_GTK_GRAB_KEY = 108;
final static int NON_STANDARD_XEMBED_GTK_UNGRAB_KEY = 109; final static int NON_STANDARD_XEMBED_GTK_UNGRAB_KEY = 109;
...@@ -151,8 +150,6 @@ public class XEmbedHelper { ...@@ -151,8 +150,6 @@ public class XEmbedHelper {
return "NON_STANDARD_XEMBED_GTK_UNGRAB_KEY"; return "NON_STANDARD_XEMBED_GTK_UNGRAB_KEY";
case NON_STANDARD_XEMBED_GTK_GRAB_KEY: case NON_STANDARD_XEMBED_GTK_GRAB_KEY:
return "NON_STANDARD_XEMBED_GTK_GRAB_KEY"; return "NON_STANDARD_XEMBED_GTK_GRAB_KEY";
case _SUN_XEMBED_START:
return "XEMBED_START";
case XConstants.KeyPress | XEmbedServerTester.SYSTEM_EVENT_MASK: case XConstants.KeyPress | XEmbedServerTester.SYSTEM_EVENT_MASK:
return "KeyPress"; return "KeyPress";
case XConstants.MapNotify | XEmbedServerTester.SYSTEM_EVENT_MASK: case XConstants.MapNotify | XEmbedServerTester.SYSTEM_EVENT_MASK:
......
...@@ -177,13 +177,6 @@ public class XEmbedServerTester implements XEventDispatcher { ...@@ -177,13 +177,6 @@ public class XEmbedServerTester implements XEventDispatcher {
embedCompletely(); embedCompletely();
} }
public void test3_2() {
embedCompletely();
int res = getEventPos();
sendMessage(XEmbedHelper._SUN_XEMBED_START);
waitEmbeddedNotify(res);
}
public void test3_3() { public void test3_3() {
reparent = true; reparent = true;
embedCompletely(); embedCompletely();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册