Commit Graph

793 Commits

Author SHA1 Message Date
edburns%acm.org
d4d3b39a3d up_version_to_a5 2005-08-21 01:23:11 +00:00
edburns%acm.org
9e304950ae Next step is to figure out why real dom listeners don't work.
M webclient/test/manual/src/classes/org/mozilla/webclient/test/TestBrowser.java

- Modify mouseOver to output some dom information to the status bar.
2005-08-21 00:53:09 +00:00
edburns%acm.org
859bfcad5f Expose the dom Node to the standard java key and mouse
listeners, using test driven development techniques of course.

Next step is to update the test browser to use this feature.

SECTION:

A webclient/classes_spec/org/mozilla/webclient/WCKeyEvent.java

- KeyEvent subclass to expose WebclientEvent, and allow access to the
  Source property, which is a dom Node

M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/EventRegistrationImpl.java

- change to handle WCKeyEvent

M webclient/test/automated/src/classes/org/mozilla/webclient/KeyListenerTest.java
M webclient/test/automated/src/classes/org/mozilla/webclient/MouseListenerTest.java

- new test content

M webclient/test/automated/src/test/KeyListenerTest1.html

- add id attribute
2005-08-20 19:25:52 +00:00
edburns%acm.org
19dc7352a7 This change-bundle solves the dom problem in a different way: by
allowing the standard java key and mouse event listeners to get access
to the dom Node that corresponds to that event.  I have the Node
propagated out to the webclient level, but I need to push it all the way
out so the client can access it.

Next step is to expose the dom Node to the standard java key and mouse
listeners, using test driven development techniques of course.

SECTION: Changes

M dom/classes/org/mozilla/dom/DOMAccessor.java

- make getNodeByHandle(long p) public so I can get the dom node for a
  key or mouse event.

M dom/classes/org/mozilla/dom/NodeImpl.java

- added commented out methods for the Node in Java SE 5.0

M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/EventRegistrationImpl.java

- Extract the dom Node that corresponds to a key or mouse event.

M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/RDFTreeNode.java

- Don't use keyword enum, for Java SE 5.0

M webclient/src_moz/EmbedEventListener.cpp

- store the long into the properties.

M webclient/src_share/jni_util.cpp
M webclient/src_share/jni_util.h

- new constant, NodeLong.
2005-08-19 05:26:07 +00:00
edburns%acm.org
fdbc87a6d5 Next step is to resume hunting down the DOM bug.
M dom/src/Makefile.in

- conditional builds to work properly XP

M webclient/build-tests.xml

- pass MOZ_SRC to test environment to enable absolute pathing to golden
  files

M webclient/test/automated/src/classes/org/mozilla/webclient/WebclientTestCase.java

- Leverage MOZ_SRC to get absolute pathing to golden files
2005-08-09 04:43:00 +00:00
bzbarsky%mit.edu
9aa3066a02 More uses of EmptyC?String(). Bug 232691, patch by Charles Fenwick
<clf03f@garnet.acns.fsu.edu>, r+sr=bzbarsky, a=bsmedberg
2005-07-15 21:41:47 +00:00
edburns%acm.org
62ece01069 generic_native_drawing_works_but_not_for_mozilla 2005-05-23 01:10:22 +00:00
edburns%acm.org
307d596df4 Remove debugging printfs.
Have browser window visible, but no content pane.
2005-05-17 13:12:45 +00:00
edburns%acm.org
220f3b897a cocoa-seems-to-work 2005-05-17 04:38:38 +00:00
edburns%acm.org
4e954005fe Turns out the problem with the CocoaBrowserControlCanvas
was that I was incorrectly interpreting the return value from
Lock().

This works.  Next step is to solve the nsWindow.cpp problem.
2005-05-16 13:39:22 +00:00
edburns%acm.org
f14f0787f1 Checkpoint for mac os x reactivation.
Having trouble with the implementation of getHandleToPeer.

Current problem is that JAWT_DrawingSurface->Lock() is failing.

Why would that be?
2005-05-13 06:40:12 +00:00
edburns%acm.org
2fe3e7e4db All I had time for today was some javadoc updates. Next step is still to
work on the dom viewer in the TestBrowser.

M webclient/classes_spec/org/mozilla/webclient/EventRegistration.java
M webclient/classes_spec/org/mozilla/webclient/EventRegistration2.java

- add javadocs.
2005-04-19 13:00:40 +00:00
edburns%acm.org
2cc96d34df This checkin enables CurrentPage.getSource() to return the actual source
bytes, including whitespace, that is being shown in the BrowserControl.
The source actually comes from the browser's cache, and is not
re-fetched over the network unless the browser doesn't have an entry in
the cache.

Next step is to fix up the TestBrowser to show off this feature.

A src_moz/LoadCompleteProgressListener.cpp
A src_moz/LoadCompleteProgressListener.h

 * Simple nsIWebProgressListener that offers a "loadComplete" property
 * that can be queried to determine if the load has completed.

A test/manual/src/classes/org/mozilla/webclient/test/DOMAccessPanel.java
A test/manual/src/classes/org/mozilla/webclient/test/DOMCellRenderer.java
A test/manual/src/classes/org/mozilla/webclient/test/DOMTreeDumper.java
A test/manual/src/classes/org/mozilla/webclient/test/DOMTreeModel.java
A test/manual/src/classes/org/mozilla/webclient/test/DOMTreeNotifier.java
A test/manual/src/classes/org/mozilla/webclient/test/DOMViewerFrame.java

- move over from Old test browser.  Produces some thread issues.

M src_moz/CurrentPageImpl.cpp

- Leverage LoadCompleteProgressListener to discover when it's safe to
  call "selectAll" on the window.

M src_moz/Makefile.in

- add LoadCompleteProgressListener

M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java

- re-enable GetSource test

M test/automated/src/test/ViewSourceTest.html

- re-edit for ease of comparison in CurrentPageTest

M test/manual/src/classes/org/mozilla/webclient/test/TestBrowser.java

- Hack: viewSource button.  A menu would be better.
2005-04-17 20:19:46 +00:00
edburns%acm.org
3fa6d2fc2e CheckPoint. Exact bytes of viewSource doesn't work yet. I think the
problem is that selectAll isn't working due to the window not being
realized.  We'll see.  Next step is to get it working!

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

- rewrite getSource() to call native code, instead of using the DOM.

M src_moz/CurrentPageImpl.cpp

- re-enable nativeGetSource().

M src_moz/EmbedWindow.cpp
M src_moz/EmbedWindow.h

- fill out dtor

- add InitNoChrome.


M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java

- comment out test

classes_spec/org/mozilla/webclient/impl/wrapper_native/CurrentPageImpl.java src_moz/CurrentPageImpl.cpp src_moz/EmbedWindow.cpp src_moz/EmbedWindow.h test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java
2005-03-29 05:03:12 +00:00
edburns%acm.org
0535edc189 This checkin re-implements CurrentPage.getSource(). It doesn't preserve
the whitespace formatting of the current page, which is a big problem.
Next step is to get the DOMViewer working with the TestBrowser.

M build.xml

- exclude test from the default build

A classes_spec/org/mozilla/webclient/impl/DOMTreeDumper.java

- Copy this over from test.

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

- leverage DOMTreeDumper to print the current source.

M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java
A test/automated/src/test/ViewSourceTest.html

- exercise new methods.
2005-03-22 15:58:51 +00:00
edburns%acm.org
f84022a1d8 [11-StateSavingWindowId]
This change-bundle implements the FULL proposal for this, as well as
covering some corner-cases not in the initial proposal.

I have yet to get the last stamp of approval from the EG, but I'm
confident we'll get it, so I'm checking it in now.

r=visvan.

SECTION: API Changes

M jsf-api/src/javax/faces/application/StateManager.java

- reword the class description for readability

- saveSerializedView

  Deprecate this.  Make it no-longer abstract.  Provide default impl
  that returns null.

- saveView

  new method.  Replaces saveSerializedView.  Provide default impl that
  calls through to saveSerializedView().


- writeState that takes Object

  new method.  Provide default impl:

+     * <p>For backwards compatability with existing
+     * <code>StateManager</code> implementations, the default
+     * implementation of this method checks if the argument is an
+     * instance of <code>Object []</code> of length greater than or
+     * equal to two.  If so, it creates a <code>SerializedView</code>
+     * instance with the tree structure coming frome element zero and
+     * the component state coming from element one and calls through to
+     * {@link
+     * #writeState(javax.faces.context.FacesContext,javax.faces.application.StateManager.SerializedView}.
+     * If not, does nothing.</p>

- getTreeStructureToSave
- getComponentStateToSave
- restoreTreeStructure
- restoreComponentState

  Deprecate these.  Provide default impl that returns null or no-ops.

- SerializedView

  Deprecate this.

M jsf-api/src/javax/faces/application/StateManagerWrapper.java

- add new methods.

M jsf-api/src/javax/faces/render/ResponseStateManager.java

- writeState that takes Object

  new method.

+     * <p>For backwards compatability with existing
+     * <code>ResponseStateManager</code> implementations, the default
+     * implementation of this method checks if the argument is an
+     * instance of <code>SerializedView</code>.  If so, it calls through
+     * to {@link
+     * #writeState(javax.faces.context.FacesContext,javax.faces.application.StateManager.SerializedView}.
+     * If not, does nothing.</p>

- writeState that takes SerializedView

+     * @deprecated This method has been replaced by {@link
+     * #writeState(javax.faces.context.FacesContext,java.lang.Object)}.
+     * The default implementation of this method does nothing.
+     *

- getState

  new method.

- getTreeStructureToRestore
- getComponentStateToRestore

  Deprecate these.  Provide default impl that returns null or no-ops.

SECTION: RI Changes

M jsf-ri/src/com/sun/faces/application/StateManagerImpl.java

  Provide implementations for deprecated methods that will be called by
  the default implementations of the new methods in StateManager.

  - saveSerializedView(): no functional change since last version

M jsf-ri/src/com/sun/faces/application/ViewHandlerImpl.java

- move the responsibility for doing the redirect to createView() from
  renderView(), since it was only designed to catch the initial request.

M jsf-ri/src/com/sun/faces/lifecycle/RestoreViewPhase.java

- introduce private isPostback() method.

+     * @return true if the request method is POST or PUT, or the method
+     * is GET but there are query parameters, or the request is not an
+     * instance of HttpServletRequest.

  Only call restoreView() if isPostback(), otherwise call createView().

M jsf-ri/src/com/sun/faces/renderkit/ResponseStateManagerImpl.java

- modify getTreeStructureToRestore() so it knows the value of the hidden
  field is only a string, not a base64 encoded object tree, if the
  stateSavingMethod is server.

- modify writeState() to not encode the view if we're saving state in
  the server, just write out the id.

- remove unused replaceMarkers method.

M jsf-ri/src/com/sun/faces/taglib/jsf_core/ViewTag.java

- leverage new APIs and rely on impl to delegate to deprecated APIs for
  backwards compatability.

M jsf-ri/systest/build-tests.xml
M jsf-ri/systest/src/com/sun/faces/htmlunit/AbstractTestCase.java
M jsf-ri/systest/src/com/sun/faces/jsptest/JspIntegrationTestCase.java
M jsf-ri/test/com/sun/faces/FacesTestCaseService.java
M jsf-ri/test/com/sun/faces/lifecycle/TestApplyRequestValuesPhase.java
M jsf-ri/test/com/sun/faces/lifecycle/TestLifecycleImpl_initial.java
M jsf-ri/test/com/sun/faces/lifecycle/TestPhase.java
M jsf-ri/test/com/sun/faces/lifecycle/TestProcessValidationsPhase.java
M jsf-ri/test/com/sun/faces/lifecycle/TestRestoreViewPhase.java
M jsf-ri/web/test/RenderResponse_correct
M jsf-ri/web/test/TestLifecycleImpl_initial_correct
M jsf-ri/web/test/TestViewHandlerImpl_correct

- Oof, mondo changes here.
2005-03-17 01:56:55 +00:00
edburns%acm.org
b0b9d3608a This checkin starts updating the javadocs. Wow. Some of these docs
haven't been touched since 1998!

A dom/classes/org/mozilla/dom/package.html
A dom/classes/org/mozilla/dom/util/package.html
A util/classes/org/mozilla/util/package.html
A webclient/classes_spec/org/mozilla/webclient/overview.html
A webclient/classes_spec/org/mozilla/webclient/package.html
M dist/build.xml
M util/classes/org/mozilla/util/Debug.java
M util/classes/org/mozilla/util/Log.java
M util/classes/org/mozilla/util/Range.java
M util/classes/org/mozilla/util/Utilities.java
M webclient/classes_spec/org/mozilla/webclient/BrowserControl.java
M webclient/classes_spec/org/mozilla/webclient/BrowserControlFactory.java
M webclient/classes_spec/org/mozilla/webclient/ImplObject.java
M webclient/classes_spec/org/mozilla/webclient/Navigation2.java
M webclient/classes_spec/org/mozilla/webclient/WebclientFactory.java
M dom/classes/org/mozilla/dom/events/MouseEventImpl.java

- Changes to allow generation of javadocs from full tree.
2005-03-15 03:14:16 +00:00
edburns%acm.org
a9dad9e810 This checkin starts updating the javadocs. Wow. Some of these docs
haven't been touched since 1998!

A dom/classes/org/mozilla/dom/package.html
A dom/classes/org/mozilla/dom/util/package.html
A util/classes/org/mozilla/util/package.html
A webclient/classes_spec/org/mozilla/webclient/overview.html
A webclient/classes_spec/org/mozilla/webclient/package.html
M dist/build.xml
M util/classes/org/mozilla/util/Debug.java
M util/classes/org/mozilla/util/Log.java
M util/classes/org/mozilla/util/Range.java
M util/classes/org/mozilla/util/Utilities.java
M webclient/classes_spec/org/mozilla/webclient/BrowserControl.java
M webclient/classes_spec/org/mozilla/webclient/BrowserControlFactory.java
M webclient/classes_spec/org/mozilla/webclient/ImplObject.java
M webclient/classes_spec/org/mozilla/webclient/Navigation2.java
M webclient/classes_spec/org/mozilla/webclient/WebclientFactory.java

- Start refresh of javadocs
2005-03-15 02:49:16 +00:00
edburns%acm.org
f96502fadc *** empty log message *** 2005-03-14 00:37:55 +00:00
edburns%acm.org
eb7043c0d3 This checkin enables obtaining an InputStream to read the POST body from
a request on the END_URL_LOAD event.  Please see
<http://lxr.mozilla.org/mozilla/source/java/webclient/test/automated/src/classes/org/mozilla/webclient/DocumentLoadListenerTest.java#138>
for an example.

Next step is to clean up the javadocs.

A webclient/test/automated/src/test/DocumentLoadListenerTest0.html
M webclient/src_moz/EmbedProgress.cpp
M webclient/test/automated/src/classes/org/mozilla/util/THTTPD.java
M webclient/test/automated/src/classes/org/mozilla/webclient/DocumentLoadListenerTest.java
2005-03-13 17:56:16 +00:00
edburns%acm.org
1500a6792b Checkpoint. Still waiting for advice on how to get POST inspection working.
M src_moz/EmbedProgress.cpp

- remove PageInfoListener meta-data from END_DOCUMENT_LOAD.  Didn't
  belong there.

M test/manual/src/classes/org/mozilla/webclient/test/TestBrowser.java

- print out the request method and response code.
2005-03-01 20:39:23 +00:00
edburns%acm.org
be6c10bca5 Thanks to Craig March for catching these extraneous semicolons. 2005-02-28 17:20:26 +00:00
edburns%acm.org
0d247279bf This checkin enables finding out the request method and response status
of a URL_LOAD event.  I'm still working on getting the request body via
the nsIUploadChannel interface.  Next step will be to get that working.
I'm currently running into problems where the END_URL event for a POST
doesn't have a status.  I think this is because I'm using the
Navigation.post() method rather than simulating a user post by pressing
a form submit button.

A classes_spec/org/mozilla/webclient/impl/wrapper_native/NativeInputStream.java
A src_moz/NativeInputStreamImpl.cpp

- Class to enable reading the post body from the request.

M build.xml

- add NativeInputStream to JNI generation

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

 * <p>This {@link DocumentLoadListener} subclass adds the ability to get
 * detailed information on each event. </p>
 *
 * <p>The <code>eventData</code> property of the
 * <code>DocumentLoadEvent</code> instance will be a
 * <code>java.util.Map</code>.  The following entries may be present in
 * this map for the following <code>*_EVENT_MASK</code> types in
 * <code>DocumentLoadEvent</code>.</p>
 *
 * <dl>
 *
 * <dt>For all <code>*_EVENT_MASK</code> types</dt>
 *
 * <dd><p>the map will contain an entry under the key "<code>URI</code>"
 * without the quotes.  This will be the fully qualified URI for the
 * event. </p></dd>
 *
 * <dt>For <code>START_URL_LOAD</code> type</dt>
 *
 * <dd><p>The map will contain an entry under the key
 * "<code>method</code>" without the quotes.  This will be the request
 * method for this event.  The map will also contain an entry under the
 * key "<code>headers</code>".  This entry will be a
 * <code>java.util.Map</code> of all the request headers.</p></dd>
 *
 * <dt>For <code>END_URL_LOAD</code> type</dt>
 *
 * <dd><p>The map will contain an entry under the key
 * "<code>method</code>" without the quotes.  This will be the request
 * method for this event.  The map will contain an entry under the key
 * "<code>status</code>" without the quotes.  This will be the response
 * status string from the server, such as "<code>200 OK</code>".  The
 * map will also contain an entry under the key "<code>headers</code>".
 * This entry will be a <code>java.util.Map</code> of all the response
 * headers.</p></dd>
 *
 * </dl>

M src_moz/EmbedProgress.cpp

- leverage nsIHttpChannel methods to get request method, response
  status, and post body.

M src_moz/Makefile.in

- add NativeInputStream

M src_share/jni_util.cpp
M src_share/jni_util.h

- new constants

- add variant of ThrowExceptionToJava that takes the exception class name.

M test/automated/src/classes/org/mozilla/webclient/DocumentLoadListenerTest.java

- new test content.  Post related content commented out.
2005-02-28 17:15:45 +00:00
edburns%acm.org
2bd243cbb6 This checkin re-enables printing. Thanks to Kyle Yuan from Sun Microsystems.
Next step is to take a step back and see what's best to do next!

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

- call through to print related methods

M src_moz/CurrentPageImpl.cpp

- Copy from CurrentPageActionEvents.cpp

M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java

- add test stub for print preview.
2005-02-14 02:37:51 +00:00
edburns%acm.org
ab7af6537a Next step is to try to re-enable the printing APIs. Not sure if this
will work.

A test/automated/src/test/DOMSelectionTest.html

- test CurrentPage.highlightSelection and clearAllSelections().

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

- send all native methods through the event thread

M classes_spec/org/mozilla/webclient/impl/wrapper_native/SelectionImpl.java

- never return null from toString().  Return "" instead.

M src_moz/CurrentPageImpl.cpp

- copy from CurrentPageActionEvents.cpp

M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java
M test/automated/src/classes/org/mozilla/webclient/DOMTest.java

- new test conent
2005-02-14 02:16:18 +00:00
edburns%acm.org
3eec1e730f Complete test for find. Next step is highlightSelection and
clearAllSelection.

test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java

- flesh out this test.
2005-02-12 21:29:47 +00:00
edburns%acm.org
7d41674e95 This checkin adds a capability to CurrentPage2 to get the result of the
find command.

Next step will be to add more tests.

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

- add find and findNext methods which return boolean.

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

- implement these methods

M src_moz/CurrentPageImpl.cpp

- change native methods to accomodate

M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java

- minimal test of new content.
2005-02-10 04:20:50 +00:00
edburns%acm.org
f7cfd10936 This checkin re-implements the basic find functionality. Next step is
to provide a way to return result of the find, by defining methods on
the CurrentPage2 interface.

A test/automated/src/test/FindTest0.html

- fodder for find

M src_moz/CurrentPageImpl.cpp

- copy content from CurrentPageActionEvents

M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java

- basic test.  Needs more robustness.
2005-02-07 06:21:35 +00:00
edburns%acm.org
2c25f27788 This checkin re-implements GetCurrentURL(). Next step is to implement
find in page.

M src_moz/CurrentPageImpl.cpp
M test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java
2005-02-07 05:16:22 +00:00
edburns%acm.org
d83753e0e6 This checkin re-enables
CurrentPage.copyCurrentSelectionToSystemClipboard() and provides a unit
test for it.

Next step is getCurrentURL.

A test/automated/src/classes/org/mozilla/webclient/CurrentPageTest.java

- new test suite for CurrentPage.  Currently only has
  testCopyCurrentSelectionToSystemClipboard().

M build-tests.xml

- add CurrentPage TestSuite with one test.

M src_moz/CurrentPageImpl.cpp

- re-implement nativeCopyCurrentSelectionToSystemClipboard()
2005-02-07 04:59:50 +00:00
edburns%acm.org
759319ad37 This checkin re-enables currentPage.getDOM(). Please see
<http://lxr.mozilla.org/mozilla/source/java/webclient/test/automated/src/classes/org/mozilla/webclient/DOMTest.java>
for a trivial usage example.

Next step is to continue to flesh out CurrentPage methods.

Ed

A test/automated/src/classes/org/mozilla/webclient/DOMTest.java

- show basic DOM functionality

M build-tests.xml

- Add new DOM test

M src_moz/CurrentPageImpl.cpp

- re-expose DOM functionality

M test/automated/src/test/HistoryTest0.html

- Add an ID to the anchor so we can do getElementById() on it.
2005-02-04 15:43:47 +00:00
edburns%acm.org
0c3c330e4c Preferences.java
- Add javadoc describing the cookie property
2005-01-19 14:01:24 +00:00
edburns%acm.org
8c4d4400a3 ? build.test
? hs_err_pid2436.log
? junit.properties
? logfile.txt
? src_moz/webclient.ilk
? src_moz/webclient.pdb
? src_moz/win32/org_mozilla_webclient_impl_wrapper_0005fnative_Win32BrowserControlCanvas.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_BookmarksImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_CurrentPageImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_EventRegistrationImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_HistoryImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_ISupportsPeer.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_NativeEventThread.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_NavigationImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_PreferencesImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_ProfileManagerImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_RDFEnumeration.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_RDFTreeNode.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_WindowControlImpl.h
? src_share/org_mozilla_webclient_impl_wrapper_0005fnative_WrapperFactoryImpl.h
? src_share/wc_share.pdb
? test/automated/src/classes/org/mozilla/webclient/.nbattrs
M test/automated/src/classes/org/mozilla/webclient/WindowCreatorTest.java
2005-01-19 13:33:31 +00:00
edburns%acm.org
68b4ab9c50 This checkin has the basic functionality of NewWindowListener
re-implemented using the new event model.  It's a bit cleaner.

Next step is to uncomment the selection check at the end of
WindowCreatorTest.java.  This code currently causes the VM to crash.  I
also plan to do some testing on the chrome flags.

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

- deprecate {add,remove}NewWindowListener(), replace with
  setNewWindowListener().

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

- added BrowserControl property, which the user sets into the event.

M classes_spec/org/mozilla/webclient/impl/wrapper_native/EventRegistrationImpl.java

- change newWindowListeners List ivar to newWindowListener ivar.

- fix {add,remove}NewWindowListener() to leverage setNewWindowListener()

- change nativeEventOccurred() to return an int instead of void.

- add boolean property nativeSetNewWindowListenerAttached()

M classes_spec/org/mozilla/webclient/impl/wrapper_native/NativeEventThread.java

- modify pushBlockingWCRunnable() to execute the runnable right away if
  we're already on the NativeEventThread.  This is necessary to allow
  re-entrancy.

M src_moz/EmbedEventListener.cpp
M src_moz/EmbedEventListener.h

- expose the mEventRegistration ivar via a getter.

M src_moz/EventRegistrationImpl.cpp
M src_moz/NativeBrowserControl.cpp
M src_moz/NativeBrowserControl.h

- add nativeSetNewWindowListenerAttached(), which calls through and sets
  it on the NativeBrowserControl.

M src_moz/WindowCreator.cpp

- implement CreateChromeWindow2, which is called when the browser needs
  a new window.

M src_share/jni_util.cpp
M src_share/jni_util.h

- change util_SendEventToJava() to return int.

M test/automated/src/classes/org/mozilla/webclient/WindowCreatorTest.java
2005-01-18 15:20:52 +00:00
edburns%acm.org
df785dc1ba This checkin provides a sketch of how I plan to re-implement the
NewWindowListener mechanism.  Next step will be to continue to try to
get it working.

A test/automated/src/classes/org/mozilla/webclient/WindowCreatorTest.java
A test/automated/src/test/WindowCreatorTest0.html
A test/automated/src/test/WindowCreatorTest1.html

- new test, currently fails.

M build-tests.xml

- add new test, non-running

M classes_spec/org/mozilla/webclient/impl/wrapper_native/EventRegistrationImpl.java

- prep for NewWindowListener

M src_moz/WindowCreator.cpp

- sketch implementation plan.  In WindowCreator.CreateChromeWindow2:

+        /*
+          Block this thread.
+
+          Call back into java and ask the user to create a top level
+          window and hand it, or an added child of it, to us.  Call this
+          thing the userWindow.
+
+          Create a new BrowserControl, get its BrowserControlCanvas and
+          make it be a child of the userWindow.
+
+          Set the userWindow and the BrowserControlCanvas to visible ==
+          true.  This is necessary to get the cause the underlying
+          mozilla window to be created.
+
+          java returns the C++ nativeBrowserControl to us.  Cast it to a
+          native NativeBrowserControl C++ object instance.  If the
+          nsIURI is non-null, cause the new window to navigate to that
+          URI.  Return the NativeBrowserControl's EmbedWindow instance,
+          which is an impl of nsIWebBrowserChrome.
+
+          I'm not sure if it's safe to do all this on the same thread on
+          which mozilla calls us.  I hope so.
+        */
2005-01-11 07:02:12 +00:00
edburns%acm.org
94c643218c This correctly implements the keyListener logic. I had the mapping
between mozilla concepts and java concepts wrong before.  The correct
mapping is:

Mozilla concept       Java concept

KeyDown               keyPressed
KeyUp                 keyReleased
KeyPress              keyTyped

KeyCode               keyCode
CharCode              keyChar

M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/EventRegistrationImpl.java

- Force the keyCode to be VK_UNDEFINED if this is a KEY_TYPED event.

- For security, log any exceptions thrown during ctor of KeyEvent.

M webclient/src_moz/EmbedEventListener.cpp

- remove unused automatic vars.

M webclient/src_moz/NavigationImpl.cpp

- roll back change done by Brian Ryner, since it doesn't make sense
  under mozilla 1.7.

M webclient/src_share/jni_util.cpp

- reverse mapping of CHAR_CODE and KEY_CODE to their java counterparts.

M webclient/test/automated/src/classes/org/mozilla/webclient/KeyListenerTest.java

- Add in some code to make it easier to run this testcase in a manual
  fashion.
2004-12-01 15:46:23 +00:00
edburns%acm.org
a53c25ab6a This checkin enables the KeyListener feature.
A webclient/test/automated/src/classes/org/mozilla/webclient/KeyListenerTest.java
A webclient/test/automated/src/test/KeyListenerTest1.html
M webclient/build-tests.xml

- add new testcase

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

- allow KeyListeners to be added and removed.

M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/EventRegistrationImpl.java

- Lazily create listener lists.

- Change the contract of queueEvent() to discard null events silently.

- Add createKeyEvent() method.

M webclient/src_moz/EmbedEventListener.cpp

- new mask names and values, DOMDOMKeyListener_maskNames,
  DOMKeyListener_maskValues.

- flesh out Key*() events.

- add addKeyEventDataToProperties.

- use eventType to discern how to populate the properties, with either key or
  mouse data.

M webclient/src_moz/EmbedEventListener.h

- key event includes and support methods.

M webclient/src_moz/EmbedProgress.cpp

- honor new last argument to util_InitializeEventMaskValuesFromClass().

M webclient/src_share/jni_util.cpp
M webclient/src_share/jni_util.h

- new constants

+jobject CHAR_CODE;
+jobject KEY_CODE;
+jstring KEY_LISTENER_CLASSNAME;
+char *DOMKeyListener_maskNames[] = {

M webclient/src_share/jni_util_export.cpp
M webclient/src_share/jni_util_export.h

- new last argument to

 util_InitializeEventMaskValuesFromClass(const char *className,
                                         char *maskNames[],
-                                        jlong maskValues[])
+                                        jlong maskValuesLong[],
+                                        jint maskValuesInt[])

  Used when the maskValues are ints, otherwise null.
2004-12-01 03:21:23 +00:00
bryner%brianryner.com
29c70cffe8 Reduce do_GetService code bloat further by adding specialized assignment to nsCOMPtr and providing a version with no error pointer. Also make CallGetService work the same way as CallGetComponent does, as far as using frozen/non-frozen interface to service manager. Bug 264456, r=darin. 2004-11-24 22:48:45 +00:00
edburns%acm.org
ebb625024b This check-in fixes a long standing problem of not being able to use any
keyboard controls on the embedded browser.  Next step is to re-activate
the keyboard listener features.

M webclient/src_moz/EmbedProgress.cpp

- call TopLevelFocusIn to make sure we get the input focus

M webclient/src_moz/NativeBrowserControl.cpp
M webclient/src_moz/NativeBrowserControl.h

- copy TopLevelFocus{In,Out}() from EmbedPrivate.
2004-11-07 15:29:10 +00:00
edburns%acm.org
2003722eca This change-bundle fixes the long standing problem where you couldn't
run webclient at the same time mozilla was running.  It does this by
introducing a new startup command, which must be called before the first
call to BrowserControlFactory.setAppData(), like this:

	BrowserControlFactory.setProfile(startupProfile);
	BrowserControlFactory.setAppData(getBrowserBinDir());

This will cause the startupProfile to be created (if necessary) and used
as webclient's mozilla profile.  If not specified, a "webclient" profile
is created and used.  This profile sticks around on your system.

SECTION: CHANGES

M classes_spec/org/mozilla/webclient/BrowserControlFactory.java
M classes_spec/org/mozilla/webclient/WebclientFactory.java
M classes_spec/org/mozilla/webclient/impl/WebclientFactoryImpl.java

- add setProfile().

M classes_spec/org/mozilla/webclient/impl/WrapperFactory.java
M classes_spec/org/mozilla/webclient/impl/wrapper_native/WrapperFactoryImpl.java

- add setProfile() and getProfile().

M classes_spec/org/mozilla/webclient/impl/wrapper_native/ProfileManagerImpl.java

- pass the wrapperFactory's profile property to the nativeStartup().

M src_moz/ProfileManagerImpl.cpp

- logic to implement above changes

M test/automated/src/classes/org/mozilla/webclient/ProfileManagerTest.java

- test that the startupProfile feature works.
2004-11-05 06:40:27 +00:00
edburns%acm.org
9a1de340f9 This checkin just adds a little more robustness to the
MouseListenerTest.  Next step will be to solve the problem where you
can't type in text fields in forms, then to implement the key listener
functionality.

M webclient/test/automated/src/classes/org/mozilla/webclient/MouseListenerTest.java

- at least make sure that all the events do occcur
2004-10-28 13:57:59 +00:00
edburns%acm.org
8b92634836 update 2004-10-27 01:38:49 +00:00
edburns%acm.org
9f434f7ab6 update.cvsignore 2004-10-27 01:38:11 +00:00
edburns%acm.org
e4fda6cb96 This checkin enables MouseListener functionality. You can add a
MouseListener to the EventRegistration or BrowserControlCanvas and be
notified of events on the browser canvas.  You can snoop for onMouseOver
information such as links.  Next step is to cvs remove unused classes
relating to mouse events, for example WCMouseListenerImpl and
WCEventListenerWrapper.

A webclient/test/automated/src/classes/org/mozilla/webclient/MouseListenerTest.java

- exercise mouseListener added to BrowserControlCanvas and to
  EventRegistration.

M webclient/build-tests.xml

- hook up new test

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

- enable adding the MouseListener from here.

M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/EventRegistrationImpl.java

- absorb the functionality of WCMouseListenerImpl.  Also need to remove
  WCEventListenerWrapper.

- deal with MouseEvents.

- refactor BrowserToJavaEventPump.run() to handle mouse listeners

M webclient/src_moz/EmbedEventListener.cpp
M webclient/src_moz/EmbedEventListener.h

- absorb functionality from CBrowserContainer relating to mouse events.

M webclient/src_moz/NativeBrowserControl.cpp

- set the EventRegistration into the EmbedEventListener instance.

M webclient/test/manual/src/classes/org/mozilla/webclient/test/TestBrowser.java

- add mouseover url updating to status bar.
2004-10-27 01:33:57 +00:00
edburns%acm.org
416da4356a Move this forward to leverage the THTTPD services of WebclientTestCase. 2004-10-26 19:33:15 +00:00
edburns%acm.org
16e0fa30d4 This checkin enables the mozilla side of mouse and key listener
behavior.  Next step is to enable the java side in test-first design
fashion.

A webclient/src_moz/EmbedEventListener.cpp
A webclient/src_moz/EmbedEventListener.h

- carried over directly from GtkMozEmbed, minus GTK code.

M webclient/src_moz/EmbedProgress.cpp

- call to NativeBrowserControl::ContentStateChange() to hook up listeners.

M webclient/src_moz/Makefile.in

- add new EmbedEventListener.cpp file

M webclient/src_moz/NativeBrowserControl.cpp
M webclient/src_moz/NativeBrowserControl.h

- new methods for hooking up listeners.
2004-10-23 05:26:08 +00:00
edburns%acm.org
8f7328158d This checkin adds request header sniffing. Not sure how useful this is,
but I wanted it for completeness with respect to response header
sniffing.

M webclient/src_moz/EmbedProgress.cpp

- visit request headers on startUrlLoad.

M webclient/test/automated/src/classes/org/mozilla/webclient/DocumentLoadListenerTest.java
M webclient/test/manual/src/classes/org/mozilla/webclient/test/TestBrowser.java

- exercise new code.
2004-10-20 02:50:44 +00:00
edburns%acm.org
a4648dbbaf M dist/build.xml
M dist/webclient-dist.xml
M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/WrapperFactoryImpl.java

- rollback 2.0 alpha b changes.  Thanks to Annie Lau.
2004-10-20 02:16:16 +00:00
edburns%acm.org
63ed119bc3 This checkin removes bookmarks support from webclient by not
initializing the bookmarks engine.  Next step is to work with the
mozilla embedding people to see how I can fix this.  What I'd like to do
is *NOT* use the GRE, but rather use the mozilla suite installation.

SECTION: Changes

M dist/build.xml

- rename release to 2_0_a2b

- made the test run from the mozilla suite installation directory

- clean out the generated batch file or sh file.

M dist/webclient-dist.xml

- made the build.xml generate a batch file, that sets the proper env
  vars, then calls back to this build.xml and executes the
  run.test.browser target.

M webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/WrapperFactoryImpl.java

- don't pull in Bookmarks, since it's not in the GRE.

SECTION: Diffs

Index: dist/build.xml
===================================================================
RCS file: /cvsroot/mozilla/java/dist/build.xml,v
retrieving revision 1.4
diff -u -r1.4 build.xml
--- dist/build.xml	15 Oct 2004 16:39:07 -0000	1.4
+++ dist/build.xml	18 Oct 2004 14:03:36 -0000
@@ -30,7 +30,7 @@

   <property name="Name" value="webclient"/>
   <property name="name" value="webclient"/>
-  <property name="version" value="2_0_a2"/>
+  <property name="version" value="2_0_a2b"/>

 <!-- ************ Per user local properties ******************************* -->

@@ -136,9 +136,13 @@
     </zip>
   </target>

-  <target name="test.dist" depends="prepare,clean.dev.build">
-
+  <target name="unzip.dist" depends="prepare">
     <unzip dest="${moz.install.dir}" src="${dist.home}/${name}_${version}_${platform}.zip" />
+  </target>
+
+  <target name="test.dist" depends="prepare">
+
+    <antcall target="unzip.dist" />

     <ant inheritAll="false" dir="${moz.install.dir}"/>

@@ -149,6 +153,8 @@
   <target name="clean.test.dist" depends="props">

     <delete file="${moz.install.dir}/build.xml" />
+    <delete file="${moz.install.dir}/runwc.bat" />
+    <delete file="${moz.install.dir}/runwc.sh" />
     <delete file="${moz.install.dir}/components/${so.prefix}javadom.${so.extension}" />
     <delete file="${moz.install.dir}/${so.prefix}javadomjni.${so.extension}" />
     <delete file="${moz.install.dir}/${so.prefix}${name}.${so.extension}" />
Index: dist/webclient-dist.xml
===================================================================
RCS file: /cvsroot/mozilla/java/dist/webclient-dist.xml,v
retrieving revision 1.2
diff -u -r1.2 webclient-dist.xml
--- dist/webclient-dist.xml	15 Oct 2004 16:39:07 -0000	1.2
+++ dist/webclient-dist.xml	18 Oct 2004 14:03:36 -0000
@@ -3,6 +3,20 @@
   <property environment="myenv" />

   <target name="props">
+    <condition property="is.win32" value="true">
+      <and>
+        <os family="windows" />
+      </and>
+    </condition>
+
+    <condition property="is.unix" value="true">
+      <and>
+        <os family="unix" />
+      </and>
+    </condition>
+
+
+
     <condition property="PATH_SEP" value=";">
       <and>
         <os family="windows" />
@@ -55,7 +69,31 @@

   </target>

-  <target name="main" depends="props">
+  <target name="main" depends="main.win32,main.unix"/>
+
+  <target name="main.win32" depends="props" if="is.win32">
+
+    <delete file="${basedir}/runwc.bat" />
+    <echo file="${basedir}/runwc.bat">
+SET PATH=${java.libpath};%PATH%
+SET NSPR_LOG_MODULES=webclient:4,webclientstub:4
+SET NSPR_LOG_FILE=webclient.log
+ant run.test.browser
+    </echo>
+    <exec command=".\runwc.bat" newenvironment="true" />
+
+  </target>
+
+  <target name="main.unix" depends="props" if="is.unix">
+
+    <delete file="${basedir}/runwc.sh" />
+    <echo file="${basedir}/runwc.sh">
+    </echo>
+
+  </target>
+
+
+  <target name="run.test.browser" depends="props">

     <java newenvironment="true"
           classname="org.mozilla.webclient.test.TestBrowser"
Index: webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/WrapperFactoryImpl.java
===================================================================
RCS file: /cvsroot/mozilla/java/webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/WrapperFactoryImpl.java,v
retrieving revision 1.8
diff -u -r1.8 WrapperFactoryImpl.java
--- webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/WrapperFactoryImpl.java	17 Jun 2004 21:27:55 -0000	1.8
+++ webclient/classes_spec/org/mozilla/webclient/impl/wrapper_native/WrapperFactoryImpl.java	18 Oct 2004 14:03:37 -0000
@@ -316,7 +316,8 @@

 			((Service)WrapperFactoryImpl.this.profileManager).startup();
 			((Service)WrapperFactoryImpl.this.prefs).startup();
-			((Service)WrapperFactoryImpl.this.bookmarks).startup();
+			// PENDING(edburns): see Message-ID: <bbf0af98.0410171147.3109d532@posting.google.com> on n.p.m.java
+			// ((Service)WrapperFactoryImpl.this.bookmarks).startup();

 			WrapperFactoryImpl.this.nativeAppSetup(nativeWrapperFactory);
 			return null;
2004-10-18 14:08:22 +00:00
edburns%acm.org
b6b9de1e28 M dist/build.xml
M dist/webclient-dist.xml

- first crack at making this work with a mozilla 1.7 suite install
2004-10-15 16:39:07 +00:00