Author= Daniel Park

r=edburns

SECTION: classes changes

M build.xml

- Removed spurious linebreak on Kyle's create.webclient.scripts.

M classes_spec/org/mozilla/webclient/BrowserControlCanvas.java

- Bugfix from Daniel Park

M classes_spec/org/mozilla/webclient/test/EMWindow.java

- Leverage new CurrentPage2 interface to display the Selection object.

M classes_spec/org/mozilla/webclient/wrapper_native/CurrentPageImpl.java
M classes_spec/org/mozilla/webclient/wrapper_nonnative/CurrentPageImpl.java

- Implement new methods from CurrentPage2.

M src_moz/CurrentPageActionEvents.cpp
M src_moz/CurrentPageActionEvents.h
M src_moz/CurrentPageImpl.cpp
M src_moz/gtk/GtkBrowserControlCanvasStub.cpp
M src_moz/gtk/StubFunctions.h

Native details for CurrentPage2.

SECTION: New files

A classes_spec/org/mozilla/webclient/Selection.java
A classes_spec/org/mozilla/webclient/CurrentPage2.java
A classes_spec/org/mozilla/webclient/wrapper_native/SelectionImpl.java


git-svn-id: svn://10.0.0.236/trunk@140912 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
edburns%acm.org
2003-04-09 17:42:41 +00:00
parent cd3d35d3ff
commit ed7795ffac
13 changed files with 756 additions and 17 deletions

View File

@@ -51,6 +51,66 @@ JNIEXPORT void JNICALL Java_org_mozilla_webclient_wrapper_1native_CurrentPageImp
}
JNIEXPORT void JNICALL Java_org_mozilla_webclient_wrapper_1native_CurrentPageImpl_nativeGetSelection
(JNIEnv *env, jobject obj, jint webShellPtr, jobject selection)
{
WebShellInitContext *initContext = (WebShellInitContext *) webShellPtr;
if (initContext == nsnull) {
::util_ThrowExceptionToJava(env, "Exception: null webShellPtr passed nativeGetSelection");
return;
}
PR_ASSERT(initContext->initComplete);
if (selection == nsnull) {
::util_ThrowExceptionToJava(env, "Exception: null Selection object passed to raptorWebShellGetSelection");
return;
}
wsGetSelectionEvent *actionEvent = new wsGetSelectionEvent(env, initContext, selection);
PLEvent *event = (PLEvent *) *actionEvent;
::util_PostSynchronousEvent(initContext, event);
}
JNIEXPORT void JNICALL Java_org_mozilla_webclient_wrapper_1native_CurrentPageImpl_nativeHighlightSelection
(JNIEnv *env, jobject obj, jint webShellPtr, jobject startContainer, jobject endContainer, jint startOffset, jint endOffset)
{
WebShellInitContext *initContext = (WebShellInitContext *) webShellPtr;
if (initContext == nsnull) {
::util_ThrowExceptionToJava(env, "Exception: null webShellPtr passed to nativeHighlightSelection");
return;
}
PR_ASSERT(initContext->initComplete);
wsHighlightSelectionEvent *actionEvent = new wsHighlightSelectionEvent(env, initContext, startContainer, endContainer, (PRInt32) startOffset, (PRInt32) endOffset);
PLEvent *event = (PLEvent *) *actionEvent;
::util_PostSynchronousEvent(initContext, event);
}
JNIEXPORT void JNICALL Java_org_mozilla_webclient_wrapper_1native_CurrentPageImpl_nativeClearAllSelections
(JNIEnv *env, jobject obj, jint webShellPtr)
{
WebShellInitContext *initContext = (WebShellInitContext *) webShellPtr;
if (initContext == nsnull) {
::util_ThrowExceptionToJava(env, "Exception: null webShellPtr passed to nativeClearAllSelections");
return;
}
PR_ASSERT(initContext->initComplete);
wsClearAllSelectionEvent *actionEvent = new wsClearAllSelectionEvent(initContext);
PLEvent *event = (PLEvent *) *actionEvent;
::util_PostSynchronousEvent(initContext, event);
}
/*
* Class: org_mozilla_webclient_wrapper_0005fnative_CurrentPageImpl
* Method: nativeFindInPage