GtkEmbeddedWindowPeer.java (construct): Remove method declaration.

2003-09-16  Thomas Fitzsimmons  <fitzsim@redhat.com>

	* gnu/java/awt/peer/gtk/GtkEmbeddedWindowPeer.java (construct):
	Remove method declaration.
	(create()): Call native create.
	(create(int)): New method.
	* jni/gtk-peer/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.c:
	(create): Add window_id parameter.  Call gtk_plug_new with
	window_id parameter.
	(construct): Remove method implementation.

From-SVN: r71453
This commit is contained in:
Thomas Fitzsimmons 2003-09-17 04:39:34 +00:00 committed by Thomas Fitzsimmons
parent 2db99d0587
commit cc16baeb1b
3 changed files with 22 additions and 23 deletions

View File

@ -1,3 +1,14 @@
2003-09-16 Thomas Fitzsimmons <fitzsim@redhat.com>
* gnu/java/awt/peer/gtk/GtkEmbeddedWindowPeer.java (construct):
Remove method declaration.
(create()): Call native create.
(create(int)): New method.
* jni/gtk-peer/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.c:
(create): Add window_id parameter. Call gtk_plug_new with
window_id parameter.
(construct): Remove method implementation.
2003-09-16 Mohan Embar <gnustuff@thisiscool.com>
* Makefile.am: (MOSTLYCLEANFILES) Removed libtool objects.

View File

@ -1,4 +1,5 @@
/* GtkEmbeddedWindowPeer.java -- Implements FramePeer using a GtkPlug
/* GtkEmbeddedWindowPeer.java -- Implements EmbeddedWindowPeer using a
GtkPlug
Copyright (C) 2003 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@ -44,12 +45,15 @@ import gnu.java.awt.peer.EmbeddedWindowPeer;
public class GtkEmbeddedWindowPeer extends GtkFramePeer
implements EmbeddedWindowPeer
{
native void create();
native void construct (int window_id);
native void create(int window_id);
void create ()
{
create (((EmbeddedWindow) awtComponent).getHandle());
}
public GtkEmbeddedWindowPeer (EmbeddedWindow w)
{
super (w);
construct (w.getHandle());
}
}

View File

@ -42,15 +42,14 @@ exception statement from your version. */
JNIEXPORT void JNICALL
Java_gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer_create
(JNIEnv *env, jobject obj)
(JNIEnv *env, jobject obj, jint window_id)
{
gpointer window;
GtkWidget *window;
GtkWidget *vbox, *layout;
gdk_threads_enter ();
/* Create an "unplugged" GtkPlug. */
window = gtk_plug_new (0);
window = gtk_plug_new (window_id);
vbox = gtk_vbox_new (0, 0);
layout = gtk_layout_new (NULL, NULL);
@ -64,18 +63,3 @@ Java_gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer_create
NSA_SET_PTR (env, obj, window);
}
JNIEXPORT void JNICALL
Java_gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer_construct
(JNIEnv *env, jobject obj, jint window_id)
{
void *ptr;
ptr = NSA_GET_PTR (env, obj);
gdk_threads_enter ();
gtk_plug_construct (GTK_PLUG (ptr), window_id);
gdk_threads_leave ();
}