online-glom:gwt-glom.git
10 years ago1.21.8 1.21.8
Murray Cumming [Thu, 12 Apr 2012 07:58:16 +0000 (09:58 +0200)]
1.21.8

10 years agoAdapt to the java-libglom 1.21.8 API.
Murray Cumming [Thu, 12 Apr 2012 07:55:13 +0000 (09:55 +0200)]
Adapt to the java-libglom 1.21.8 API.

* src/main/java/org/glom/web/server/ConfiguredDocument.java:
java-libglom's FieldFormatting is now Formatting.

10 years agoUse the latest java-libglom version.
Murray Cumming [Thu, 12 Apr 2012 07:40:05 +0000 (09:40 +0200)]
Use the latest java-libglom version.

* pom.xml: Use java-libglom 1.21.8.

10 years agoTranslations: Add Esperanto.
Murray Cumming [Thu, 12 Apr 2012 07:39:03 +0000 (09:39 +0200)]
Translations: Add Esperanto.

* src/main/java/org/glom/web/OnlineGlom.gwt.xml
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_eo.
properties: Add this translation because someone took the time to make it.

10 years agoUse the latest java-libglom version.
Murray Cumming [Thu, 15 Mar 2012 12:12:48 +0000 (13:12 +0100)]
Use the latest java-libglom version.

* pom.xml: Use java-libglom 1.21.7.

10 years agoDisplay date and time in details view.
Ben Konrath [Sat, 3 Mar 2012 21:55:55 +0000 (22:55 +0100)]
Display date and time in details view.

https://bugzilla.gnome.org/show_bug.cgi?id=671257

* src/main/java/org/glom/web/client/ui/details/DetailsCell.java:

10 years agoRemove gradient from selected tab.
Ben Konrath [Sat, 3 Mar 2012 16:04:07 +0000 (17:04 +0100)]
Remove gradient from selected tab.

10 years agoImprove the tabs in the Notebook widget.
Ben Konrath [Fri, 24 Feb 2012 11:42:23 +0000 (12:42 +0100)]
Improve the tabs in the Notebook widget.

Bug #670728

10 years ago1.21.4.1 1.21.4.1
Murray Cumming [Tue, 7 Feb 2012 09:03:43 +0000 (10:03 +0100)]
1.21.4.1

10 years agoUse translations from Glom's .po files.
Murray Cumming [Tue, 7 Feb 2012 08:36:05 +0000 (09:36 +0100)]
Use translations from Glom's .po files.

10 years agoMore Spanish translated strings.
Murray Cumming [Tue, 31 Jan 2012 08:08:10 +0000 (09:08 +0100)]
More Spanish translated strings.

10 years ago1.21.4 1.21.4
Murray Cumming [Mon, 30 Jan 2012 09:30:28 +0000 (10:30 +0100)]
1.21.4

10 years agoTranslations: Try to translate the strings.
Murray Cumming [Mon, 30 Jan 2012 09:04:52 +0000 (10:04 +0100)]
Translations: Try to translate the strings.

* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_cs.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_de.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_es.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_sl.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_zh_CN.properties:
Take the Open translation from GTK+'s .po files.
Take the Details translation from Glom's po files.
I have added the other strings to Glom so we can get translations that way:
http://git.gnome.org/browse/glom/commit/?id=c3cefe607428a84bdf8de1b04e8bef6f70b04564

10 years agoLet Eclipse format all source code.
Murray Cumming [Fri, 27 Jan 2012 21:15:43 +0000 (22:15 +0100)]
Let Eclipse format all source code.

10 years agoTableSelectionViewImpl: Put the search label and entry in a div.
Murray Cumming [Fri, 27 Jan 2012 11:39:36 +0000 (12:39 +0100)]
TableSelectionViewImpl: Put the search label and entry in a div.

* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
Put the search widgets in a FlowTable so that the CSS can be used to
style them while keeping them together.
* src/main/webapp/style.css: Mention the new div.

10 years agoTranslate more strings in more locales.
Murray Cumming [Fri, 27 Jan 2012 11:07:41 +0000 (12:07 +0100)]
Translate more strings in more locales.

* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.properties:
* src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
* src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
* src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
Translate the "Details" and "Open" string too.

* src/main/java/org/glom/web/OnlineGlom.gwt.xml:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_cs.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_es.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_sl.properties:
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_zh_CN.properties:
Add these new locales as placeholders though they currently contain English.

10 years agoOnlineGlomServiceImpl: Avoid (unlikely) null object dereferences.
Murray Cumming [Fri, 27 Jan 2012 08:41:56 +0000 (09:41 +0100)]
OnlineGlomServiceImpl: Avoid (unlikely) null object dereferences.

* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: get*():
Check the ConfiguredDocument* for null before using it.

10 years agoRemove unnecessary SuppressWarnings
Murray Cumming [Thu, 26 Jan 2012 22:28:17 +0000 (23:28 +0100)]
Remove unnecessary SuppressWarnings

10 years agoMinor formatting fixes.
Murray Cumming [Thu, 26 Jan 2012 20:00:02 +0000 (21:00 +0100)]
Minor formatting fixes.

10 years agoTell Eclipse about the generated java files.
Murray Cumming [Thu, 26 Jan 2012 19:59:46 +0000 (20:59 +0100)]
Tell Eclipse about the generated java files.

* .classpath: This lets it find OnlineGlomConstants.java.
It would be nice if Eclipse just used the maven build files.

10 years agoPrevent a crash when no locale is specified in the URL.
Murray Cumming [Thu, 26 Jan 2012 19:58:09 +0000 (20:58 +0100)]
Prevent a crash when no locale is specified in the URL.

* src/main/java/org/glom/web/client/Utils.java: getCurrentLocaleID():
Avoid returning a null string, obtained from
Window.Location.getParameter(). This caused a crash when it was
later passed to libglom's API.
* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
init(), getDocumentInfo(), getListViewLayout(), getDocuments(),
getDetailsLayoutAndData(): Use StringUtils.defaultString() to
guard against future null strings.

10 years agoFix previous commit.
Murray Cumming [Thu, 26 Jan 2012 12:30:26 +0000 (13:30 +0100)]
Fix previous commit.

10 years agoUse the ?locale= query param instead of the &lang= token param.
Murray Cumming [Thu, 26 Jan 2012 12:22:26 +0000 (13:22 +0100)]
Use the ?locale= query param instead of the &lang= token param.

* src/main/java/org/glom/web/client/place/ListPlace.java
* src/main/java/org/glom/web/client/place/DetailsPlace.java
* src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
Remove the lang token key and value.

* src/main/java/org/glom/web/client/ui/TableSelectionView.java
* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
When the user selects a different locale from the chooser, use
Window.Location.assign() to change the URL, which then causes a reload.

* src/main/java/org/glom/web/client/Utils.java: Added getCurrentLocaleID().
* src/main/java/org/glom/web/client/activity/DetailsActivity.java
* src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java
* src/main/java/org/glom/web/client/activity/ListActivity.java
* src/main/java/org/glom/web/client/activity/TableSelectionActivity
* src/main/java/org/glom/web/client/ui/DocumentSelectionView.java
* src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java:
* src/main/java/org/glom/web/client/ui/ListView.java:
* src/main/java/org/glom/web/client/ui/ListViewImpl.java:

Remove localeID member variables and method/constructor parameters, instead
using Utils.getCurrentLocaleID() when we need a localID to pass to
OnlineGlomService.

10 years agoInternationalize the UI strings.
Murray Cumming [Thu, 26 Jan 2012 10:17:29 +0000 (11:17 +0100)]
Internationalize the UI strings.

* pom.xml: gwt-maven-plugin: Add the i18n goal and specify a
<i18nConstantsBundle>, removing the unused <i18nMessagesBundle>.
* src/main/resources/org/glom/web/client/Messages.properties: Remove this
because it is unused. Messages are apparently strings that can have
parameters, but we do not need that yet, so Contants will be enough for now.
* src/main/java/org/glom/web/OnlineGlom.gwt.xml: Add extend-property lines
to say that we support the en and de locales.
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.properties:
The original English strings.
* src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_de.properties:
Some German translations of the English strings.
The i18n goal then uses the .properties file to generate an
OnlineGlomConstants.java file in target/ and somehow GWT.create() magically
returns an implementation that returns the translated strings.
The documentation suggests putting these in src/java/*/client/, but it seems
best to put it in src/resources/*/client/.
* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
Instantiate OnlineGlomConstants via GWT.create() and use it to get the strings
instead of hard-coding them.
Note that we cannot import OnlineGlomConstants because it does not exist yet,
but that does not seem to stop the build, though it confuses Eclipse.

You can see the translated string by adding ?locale=de to the URL, like so:
http://127.0.0.1:8888/OnlineGlom.html?gwt.codesvr=127.0.0.1:9997?locale=de#list:document=film_manager

10 years agoImprove null/empty String checks.
Murray Cumming [Tue, 24 Jan 2012 13:11:36 +0000 (14:11 +0100)]
Improve null/empty String checks.

* pom.xml: Add a dependency on commons-lang, to use
org.apache.commons.lang.StringUtils.
* src/main/java/org/glom/web/server/ConfiguredDocument.java
* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
* src/main/java/org/glom/web/server/database/RelatedListDBAccess.java
* src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
Use StringUtils.isEmpty().

* src/main/java/org/glom/web/client/StringUtils.java: Add a tiny
StringUtils class with a static isEmpty() function because we
cannot use org.apache.commons.lang.StringUtils in client-side
GWT code because it (apparently) cannot be compiled to javascript.
* src/main/java/org/glom/web/client/activity/DetailsActivity.java
* src/main/java/org/glom/web/client/activity/ListActivity.java
* src/main/java/org/glom/web/client/activity/TableSelectionActivity.java
* src/main/java/org/glom/web/client/place/DetailsPlace.java
* src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
* src/main/java/org/glom/web/client/place/ListPlace.java
* src/main/java/org/glom/web/client/ui/cell/NumericCell.java
* src/main/java/org/glom/web/client/ui/cell/TextCell.java
* src/main/java/org/glom/web/client/ui/details/DetailsCell.java
* src/main/java/org/glom/web/client/ui/details/Group.java
* src/main/java/org/glom/web/client/ui/details/Notebook.java: Use
our StringUtils.isEmpty() function.

10 years agoUpdate to the latest java-libglom API.
Murray Cumming [Tue, 24 Jan 2012 12:00:34 +0000 (13:00 +0100)]
Update to the latest java-libglom API.

* pom.xml: Require java-libglom 1.21.4.
* src/main/java/org/glom/web/server/ConfiguredDocument.java
getDocumentInfo(), getListViewLayoutGroup():
* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
getDocuments():
* src/main/java/org/glom/web/server/database/DBAccess.java
getFieldsToShowForSQLQueryAddGroup(),
getPrimaryKeyLayoutItemField(): Replace get_database_title()
with either get_database_title_original() or
get_database_title(localeID).

10 years agoConfiguredDocument: Avoid a null pointer exception.
Murray Cumming [Tue, 24 Jan 2012 11:34:18 +0000 (12:34 +0100)]
ConfiguredDocument: Avoid a null pointer exception.

* src/main/java/org/glom/web/server/ConfiguredDocument.java
Initialize localeID to "" to avoid returning a null String which
causes a crash in java-libglom's swing-generated code.

10 years agoSome simple renaming.
Murray Cumming [Mon, 23 Jan 2012 11:05:13 +0000 (12:05 +0100)]
Some simple renaming.

* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
* src/main/webapp/style.css: Rename, tableChooser to tablesChooser. Likewise
for localeChooser. This seems more appropriate and is less ambiguous
particularly in the .css file.

10 years agoConfiguredDocument: Rename the localedID private member variable.
Murray Cumming [Sun, 22 Jan 2012 21:24:58 +0000 (22:24 +0100)]
ConfiguredDocument: Rename the localedID private member variable.

Conflicts:

ChangeLog

10 years agoAdapt to the latest java-libglom API from git master.
Murray Cumming [Mon, 23 Jan 2012 09:51:12 +0000 (10:51 +0100)]
Adapt to the latest java-libglom API from git 

* src/main/java/org/glom/web/server/database/ListDBAccess.java:
libglom now uses only Vector instead of List, which uses add() instead of
addLast().

10 years ago1.21.1 1.21.1
Murray Cumming [Fri, 20 Jan 2012 12:31:11 +0000 (13:31 +0100)]
1.21.1

10 years agoBuild a source tarball with mvn assembly:assembly
Murray Cumming [Fri, 20 Jan 2012 12:12:14 +0000 (13:12 +0100)]
Build a source tarball with mvn assembly:assembly

* assembly.xml: Add this file.
* pom.xml: Use the maven-assembly-plugin and tell it to use
our assembly.xml file.

10 years agoOnlineGlomServiceImpl: Get .glom files recursively.
Murray Cumming [Thu, 19 Jan 2012 21:24:12 +0000 (22:24 +0100)]
OnlineGlomServiceImpl: Get .glom files recursively.

* pom.xml: Depend on commons-io from org.apache.commons.
* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
init(): Use org.apache.commons.io.FileUtils.listFiles() to get the
files recursively, and with the easier filter for the extension.
Use org.apache.commons.io.FilenameUtils.removeExtension() to
simplify that code too.

10 years agoFix a typo
Murray Cumming [Thu, 19 Jan 2012 20:32:52 +0000 (21:32 +0100)]
Fix a typo

10 years agoREADME: Mention that you must install java-libglom packages separately.
Murray Cumming [Thu, 19 Jan 2012 09:04:52 +0000 (10:04 +0100)]
README: Mention that you must install java-libglom packages separately.

But then it works, because java-libglom is now in the central maven
repository.

10 years agolocales drop-down: Show the correct selected locale when the URL changes.
Murray Cumming [Wed, 18 Jan 2012 22:05:26 +0000 (23:05 +0100)]
locales drop-down: Show the correct selected locale when the URL changes.

* src/main/java/org/glom/web/client/activity/TableSelectionActivity
.java: setPlace(): Move some code into fillView().

10 years agolocales drop-down: Do not lose the primary key.
Murray Cumming [Wed, 18 Jan 2012 21:49:46 +0000 (22:49 +0100)]
locales drop-down: Do not lose the primary key.

* src/main/java/org/glom/web/client/activity/DetailsActivity.java
start(): onLocaleChange(): Pass the current primary key value,
instead of an empty value.

10 years agolocales drop-down: Do not lose the drop-down selection.
Murray Cumming [Wed, 18 Jan 2012 21:48:39 +0000 (22:48 +0100)]
locales drop-down: Do not lose the drop-down selection.

* src/main/java/org/glom/web/client/activity/TableSelectionActivity
.java (TableSelectionActivity.fillView): Set the selected locale
after changing the drop-down items (though we do not really need
to change them just because the locale changes.)

10 years agolocales drop-down: Change the tables list when this changes.
Murray Cumming [Wed, 18 Jan 2012 21:38:32 +0000 (22:38 +0100)]
locales drop-down: Change the tables list when this changes.

* src/main/java/org/glom/web/client/activity/TableSelectionActivity
.java: TableSelectionActivity.start(): Move the async table titles
retrieval into a private fillView() method and also call this when
the chosen locale changes.
Note that the document title is not actually translatable yet, but
that is a problem that I should fix soon in libglom.

10 years agoImprove the placement of the locales drop-down.
Murray Cumming [Wed, 18 Jan 2012 10:37:40 +0000 (11:37 +0100)]
Improve the placement of the locales drop-down.

* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
Put the title and locales drop-down in a div (gwt.FlowTable).
* src/main/webapp/style.css: Add magic css properties to make this work.
Also remove the left margin from the title so that it lines up with the
headerbox below it.

10 years agolocales selector: Show human-readable locale titles.
Murray Cumming [Tue, 17 Jan 2012 23:13:33 +0000 (00:13 +0100)]
locales selector: Show human-readable locale titles.

* src/main/java/org/glom/web/server/ConfiguredDocument.java
getDocumentInfo(): Use java.util.Locale to show a real title of
each locale, in the locale's own language.

10 years agoAdd a language/locale selector drop-down.
Murray Cumming [Tue, 17 Jan 2012 22:50:35 +0000 (23:50 +0100)]
Add a language/locale selector drop-down.

* src/main/java/org/glom/web/shared/DocumentInfo.java:
Add getLocaleIDs(), setLocaleIDs(), getLocaleTitles(), setLocaleTitles().
* /src/main/java/org/glom/web/server/ConfiguredDocument.java:
getDocumentInfo(): Store the available Locales in the DocumentInfo.
* src/main/java/org/glom/web/client/ui/TableSelectionView.java:
* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
Add a ListBox to show the available locales. Add getLocaleSelector(),
setLocaleList(), getSelectedLocale(), setSelectedLocale().
* src/main/java/org/glom/web/client/event/LocaleChangeEvent.java
* src/main/java/org/glom/web/client/event/LocaleChangeEventHandler.
java: Add these classes.
* src/main/java/org/glom/web/client/activity/TableSelectionActivity.java:
start(): Fill the locales ListBox. Handle its change event, firing a
LocaleChangeEvent.
setPlace(): Show the selected locale as specified by the URL token.
* src/main/java/org/glom/web/client/activity/DetailsActivity.java:
* src/main/java/org/glom/web/client/activity/ListActivity.java:
Handle LocaleChangeEvent, going to a new *Place with that locale.

The placement of the ListBox is not pretty, and it currently uses the ID
as a title, instead of "English", "Deutsch", "Espanola", etc, but it
is a start.

10 years agoFix a typo.
Murray Cumming [Tue, 17 Jan 2012 22:27:04 +0000 (23:27 +0100)]
Fix a typo.

10 years agoSearch box: Show the search text from the URL token.
Murray Cumming [Tue, 17 Jan 2012 21:42:24 +0000 (22:42 +0100)]
Search box: Show the search text from the URL token.

* src/main/java/org/glom/web/client/ui/TableSelectionView.java:
* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
Add setQuickFindText().
* src/main/java/org/glom/web/client/activity/TableSelectionActivity
.java: setPlace(): Store the queryText if the place is a ListPlace,
and call TableSelectionView.setQuickFindText().

10 years agoAllow use of translations via, for instance, &lang=de in the URL.
Murray Cumming [Mon, 16 Jan 2012 22:33:06 +0000 (23:33 +0100)]
Allow use of translations via, for instance, &lang=de in the URL.

* pom.xml: Use the unstable java-libglom 1.21 version.

* src/main/java/org/glom/web/client/OnlineGlomService.java:
* src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java
* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
init(): Instead of calling TranslatableItem.set_current_locale()
(now removed), call ConfiguredDocument.setDefaultLocaleID().
However, this is only for default locales, which are not needed to
change the locale in the URL.
getDocumentInfo(), getListViewLayout(), getSortedListViewData(),
getDetailsData(), getDetailsLayoutAndData(), getRelatedListData(),
getSortedRelatedListData(): Add a localeID parameter, so we can get the
layout for a particular locale.
* src/main/java/org/glom/web/server/ConfiguredDocument.java:
Add get/setDefaultLocaleID().
getDocumentInfo(), getListViewData(), getRelatedListData(),
getDetailsLayoutGroup(), getListViewLayoutGroup(),
createLayoutItemPortalDTO(), convertToGWTGlomLayoutItemField(): Add a
localeID parameter, so we can get the layout for a particular locale.

* src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java:
* src/main/java/org/glom/web/client/place/DetailsPlace.java:
* src/main/java/org/glom/web/client/place/ListPlace.java:
Parse and construct a lang parameter too.

* src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java:
start(): Pass the defaultLocaleID to addDocumentLink(). It is then
passed to subsequent methods and constructors.
* src/main/java/org/glom/web/client/activity/DetailsActivity.java:
* src/main/java/org/glom/web/client/activity/ListActivity.java:
Store the localeID from the *Place and pass it to other constructors
and methods, such as OnlineGlomServiceAsync.getDetailsLayoutAndData().

* src/main/java/org/glom/web/client/ui/DocumentSelectionView.java:
* src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java:
* src/main/java/org/glom/web/client/ui/TableSelectionView.java
* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
* src/main/java/org/glom/web/client/ui/ListView.java:
* src/main/java/org/glom/web/client/ui/ListViewImpl.java:
Take localeID parameters and pass them to subsequent constructors and
methods, so that the layout is always retrieved for that locale.

This is rather repetitive.

Note that "" means the original (default) locale of the Glom document,
which is usually English.

10 years agoDocuments: Remove final keyword to fix startup configuration. libglom-1-20
Murray Cumming [Tue, 17 Jan 2012 09:39:18 +0000 (10:39 +0100)]
Documents: Remove final keyword to fix startup configuration.

* src/main/java/org/glom/web/shared/Documents.java: Remove the
final keywords on the private member variables because that breaks
the startup, apparently (there are warnings) because it stops them
from being serialized. I added these in the previous commit.

10 years agoDocuments: Add some final keywords.
Murray Cumming [Fri, 13 Jan 2012 17:23:44 +0000 (18:23 +0100)]
Documents: Add some final keywords.

* src/main/java/org/glom/web/shared/Documents.java: Eclipse suggested
this.

10 years agoOnlineGlomServiceImpl: Add to overview comments.
Murray Cumming [Fri, 13 Jan 2012 17:20:43 +0000 (18:20 +0100)]
OnlineGlomServiceImpl: Add to overview comments.

* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
Note that this is where all the document are loaded. They are not
loaded freshly for each page.

10 years agoAdd a search box.
Murray Cumming [Thu, 12 Jan 2012 23:12:35 +0000 (00:12 +0100)]
Add a search box.

* src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
Add a TextBox for the text of a quick find.
Add getQuickFindBox(), to get the widget, and getQuickFindText() to
get the text.
setBackLink(): Add a String quickFind parameter.
* src/main/java/org/glom/web/client/ui/TableSelectionView.java
(TableSelectionView): Add getQuickFindBox() and getQuickFindText()
to the base interface, because that is how TableSelectionViewImpl is used.
* src/main/webapp/style.css: Add style for the search box and its label.

* src/main/java/org/glom/web/client/event/QuickFindChangeEvent.java:
* src/main/java/org/glom/web/client/event/QuickFindChangeEventHandler.java:
Add these files, based on the existing TableChangeEvent and
TableChangeEventHandlers.
* src/main/java/org/glom/web/client/activity/DetailsActivity.java
start(): Handle QuickFindChangeEvent, passing its quickFind text to
a ListPlace() that the user should be taken to.
* src/main/java/org/glom/web/client/activity/ListActivity.java
start(): Handle it here too and adapt the TableChangeEvent handler to
pass the extra  quickFind parameter to ListPlace.
* src/main/java/org/glom/web/client/place/ListPlace.java:
Constructor: Take an extra String quickFind parameter and store it,
returning it from a new  getQuickFind() method.
getToken(): Put the quickFind text in the URL token.
getPlace(): Parse the quickFind text from the URL token.
* src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.ja
va: addDocumentLink(): Pass an extra  quickFind parameter to the
ListPlace constructor.
* src/main/java/org/glom/web/client/activity/TableSelectionActivity
.java: start(): Add a Change handler for the TableSelectionView's
TextBox (via its base HasChangeHandlers interface), firing the new
QuickFindChangeEvent.
setPlace(): Adapt the call to TableSelectionView.setbackLink(), to
pass the extra  quickFind parameter.

* src/main/java/org/glom/web/client/ui/ListViewImpl.java:
setCellTable(): Add a String quickFind parameter and pass it to
the ListViewTable() constructor.
* src/main/java/org/glom/web/client/ui/ListView.java: Change
setCellTable() in the base interface, because that is how ListViewImpl
is used.

* src/main/java/org/glom/web/client/ui/list/ListTable.java:
Add a String quickFind member variable.
* src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
Constructor: Add a String quickFind parameter, storing it in the
base ListTable's member variable.
onRangeChanged(): Pass quickFind to the
OnlineGlomServiceAsync.getSortedListViewData() and
OnlineGlomServiceAsync.getListViewData() methods.

* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
getListViewData(), getSortedListViewData(): Add a String quickFind
parameter, passing it to ConfiguredDocument.getListViewData().
* src/main/java/org/glom/web/client/OnlineGlomService.java:
Change getListViewData(), getSortedListViewData() in the base interface,
because that is how OnlineGlomServiceImpl is used, via this:
* src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java:
Change getListViewData(), getSortedListViewData() here too.
This class can apparently be used to asynchronously call methods on
OnlineGlomService, and GWT seems to implement that after recognizing
just the *Async name convention and the extra AsyncCallback parameters.

* src/main/java/org/glom/web/server/ConfiguredDocument.java
getListViewData(): Add a String quickFind parameter, and pass it to
ListViewDBAccess.getData().
* src/main/java/org/glom/web/server/database/ListDBAccess.java
getListData(): Add a String quickFind parameter and pass it to
getSelectQuery().
getSelectQuery(): Add a String quickFind parameter.
* src/main/java/org/glom/web/server/database/ListViewDBAccess.java
getSelectQuery(): Add a String quickFind parameter and use it with
Glom.get_find_where_clause_quick() to pass a where_clause to
Glom.build_sql_select_with_where_clause(), to actually filter the
list view results.
getData(): Add a String quickFind parameter, passing it to getListData().
* src/main/java/org/glom/web/server/database/Rela
va: getData(): Pass an empty string to getL
quickFind parameter.

10 years agoListTable: Minor change.
Murray Cumming [Thu, 12 Jan 2012 13:31:04 +0000 (14:31 +0100)]
ListTable: Minor change.

* src/main/java/org/glom/web/client/ui/list/ListTable.java
createCellTable(): Make this protected instead of public.

10 years agoSeveral files: Use final for the parameters and use the @override attribute.
Murray Cumming [Thu, 12 Jan 2012 09:33:10 +0000 (10:33 +0100)]
Several files: Use final for the parameters and use the @override attribute.

10 years agoMinor documentation/comment changes
Murray Cumming [Thu, 12 Jan 2012 09:24:03 +0000 (10:24 +0100)]
Minor documentation/comment changes

10 years agoCorrect the ChangeLog
Murray Cumming [Wed, 11 Jan 2012 21:12:32 +0000 (22:12 +0100)]
Correct the ChangeLog

10 years agoAdd anchor links for single line text that starts with http, ftp and www.
Ben Konrath [Sun, 25 Dec 2011 01:29:50 +0000 (02:29 +0100)]
Add anchor links for single line text that starts with http, ftp and 

10 years agoAdd ellipsis to single line text in details view.
Ben Konrath [Sun, 25 Dec 2011 00:00:33 +0000 (01:00 +0100)]
Add ellipsis to single line text in details view.

10 years agoUpdate a copyright year.
Murray Cumming [Wed, 4 Jan 2012 20:08:48 +0000 (21:08 +0100)]
Update a copyright year.

10 years agoRemove all javadoc author tags.
Murray Cumming [Wed, 4 Jan 2012 20:08:05 +0000 (21:08 +0100)]
Remove all javadoc author tags.

Because they are awkward and meaningless when many people touch
many files.
See https://gitorious.org/online-glom/gwt-glom/commit/7628b732cb90cbc6d5635420a75568504e8b3655#comment_81164

10 years agoCorrect the ChangeLog
Murray Cumming [Wed, 4 Jan 2012 19:59:49 +0000 (20:59 +0100)]
Correct the ChangeLog

10 years agoRevert the COPYING.LESSER to COPYING rename.
Murray Cumming [Wed, 4 Jan 2012 19:54:41 +0000 (20:54 +0100)]
Revert the COPYING.LESSER to COPYING rename.

Apparently both should be there if it is LGPL.

This partially reverts commit ed70963225640fd794cdb3e1a01043060ad3aff7.

10 years ago*View: Remove unused imports.
Murray Cumming [Tue, 3 Jan 2012 12:51:38 +0000 (13:51 +0100)]
*View: Remove unused imports.

* src/main/java/org/glom/web/client/ui/DetailsView.java:
* src/main/java/org/glom/web/client/ui/DocumentSelectionView.java
* src/main/java/org/glom/web/client/ui/ListView.java:
* src/main/java/org/glom/web/client/ui/TableSelectionView.java:
Remove unused imports, as suggested by Eclipse.

10 years agoMove the *View::Presenter types, and some API into one base View.
Murray Cumming [Mon, 2 Jan 2012 20:40:11 +0000 (21:40 +0100)]
Move the *View::Presenter types, and some API into one base View.

* src/main/java/org/glom/web/client/ui/DetailsView.java:
* src/main/java/org/glom/web/client/ui/DocumentSelectionView.java:
* src/main/java/org/glom/web/client/ui/ListView.java:
* src/main/java/org/glom/web/client/ui/TableSelectionView.java: Move
Presenter, setPresenter() and clear() into a shared base interface,
to avoid the unnecessary duplicate Presenter types and to more clearly
show how the *Views share the same structure, even if they are not
used polymorphically.

* src/main/java/org/glom/web/client/ui/DetailsViewImpl.java:
* src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.ja
va:
* src/main/java/org/glom/web/client/activity/DetailsActivity.java:
* src/main/java/org/glom/web/client/activity/ListActivity.java:
* src/main/java/org/glom/web/client/activity/DocumentSelectionActiv
ity.java:
* src/main/java/org/glom/web/client/activity/TableSelectionActivity
.java: Adapt.

Feel free to revert this if there is a good reason for the duplicate
types.

10 years agoOnlineGlom: Make clientFactory a (protected) member, and test it a bit.
Murray Cumming [Mon, 2 Jan 2012 19:59:19 +0000 (20:59 +0100)]
OnlineGlom: Make clientFactory a (protected) member, and test it a bit.

* src/main/java/org/glom/web/client/OnlineGlom.java: Make clientFactory
a class member instead of a local variable in the method.
This lets us use it to get the view instances, for use in tests.
* src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
beforeOnlineGlom(): Test some more details of the initial view.
Again, this is not very useful.

To really test gwt-glom we will need to start a local postgresql
instance with local data, like the Glom tests in C++.

10 years agopom.xml: Mention the LGPL license.
Murray Cumming [Mon, 2 Jan 2012 13:48:44 +0000 (14:48 +0100)]
pom.xml: Mention the LGPL license.

* pom.xml: Add a licenses section.
* COPYING.LESSER: Move this to COPYING, which
previously contained the GPL. But gwt-glom is all LGPL.

10 years agoAdd project information to README and pom.xml.
Murray Cumming [Mon, 2 Jan 2012 13:40:04 +0000 (14:40 +0100)]
Add project information to README and pom.xml.

* README: Add a brief description and mention some mvn
commands.
* pom.xml: This extra information shows up in mvn site
generated pages.

10 years agoUse the latest java-libglom version.
Murray Cumming [Thu, 22 Dec 2011 12:06:08 +0000 (13:06 +0100)]
Use the latest java-libglom version.

* pom.xml: Use java-libglom 1.19.2 instead of 1.19.1.

10 years agoGwtTestOnlineGlom: Test a little more.
Murray Cumming [Sun, 1 Jan 2012 22:49:26 +0000 (23:49 +0100)]
GwtTestOnlineGlom: Test a little more.

* src/main/java/org/glom/web/client/OnlineGlom.java: Make the panels
protected rather than private, as suggested by the gwt-test-utils
maintianer here:
http://stackoverflow.com/questions/7931724/gwt-testcase-simulating-clicking-a-button-on-my-page
* src/test/java/org/glom/web/client/GwtTestOnlineGlom.java
Test the initial visibility of the panels.

However, this is not a very useful test.
And I wonder how we should generally test using this idea for an
activity/places app like ours where the real changes happen implicitly
based on the history token/URL.

10 years agoSlight modification to *Mapper comments.
Murray Cumming [Sun, 1 Jan 2012 21:14:28 +0000 (22:14 +0100)]
Slight modification to *Mapper comments.

* src/main/java/org/glom/web/client/mvp/DataActivityMapper.java
(DataActivityMapper)
* src/main/java/org/glom/web/client/mvp/DocumentSelectionActivityMa
pper.java
* src/main/java/org/glom/web/client/mvp/TableSelectionActivityMappe
r.java
Remove comments mentioning GIN because they are just copied from
the example code and are apparently not helpful:
http://groups.google.com/group/google-web-toolkit/msg/82f0098b20669a73
Also change the mention of a class that is only in the example code.

10 years agoAdd comments with my understanding of the ClientFactory
Murray Cumming [Sun, 1 Jan 2012 21:02:23 +0000 (22:02 +0100)]
Add comments with my understanding of the ClientFactory

10 years agoGwtTestOnlineGlom test: Minor changes.
Murray Cumming [Sun, 1 Jan 2012 20:44:45 +0000 (21:44 +0100)]
GwtTestOnlineGlom test: Minor changes.

* src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
Avoid the long qualified class name and modify the comment
because it is now obvious to me that the mocked class is the only
custom one created via GWT.create().

10 years agoImprove the ChangeLog
Murray Cumming [Sun, 1 Jan 2012 00:58:56 +0000 (01:58 +0100)]
Improve the ChangeLog

10 years agoTests: Added the beginnings of a test using gwt-test-utils.
Murray Cumming [Sun, 1 Jan 2012 00:58:26 +0000 (01:58 +0100)]
Tests: Added the beginnings of a test using gwt-test-utils.

* pom.xml: Add dependencies on gwt-test-utils and easymock.
* src/test/resources/META-INF/gwt-test-utils.properties: Add this file
which tells gwt-test-utils what class will be tested.
* src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
Add a simple (but empty) test case. One class, used by the OnlineGlom
class, is mocked so that it can be created. However, I am not sure
why only this class needs to be mocked.

Note that mockito seems more popular, and clearer, than easymock,
but I have not got that working yet. It might be a matter of the
mockito version.

10 years agoTests: Use junit4-style syntax instead of junit3-style.
Murray Cumming [Sat, 31 Dec 2011 22:13:23 +0000 (23:13 +0100)]
Tests: Use junit4-style syntax instead of junit3-style.

* src/test/java/org/glom/web/client/place/DetailsPlaceTest.java:
* src/test/java/org/glom/web/client/place/ListPlaceTest.java:
* src/test/java/org/glom/web/shared/DataItemTest.java:
Use the @Test annotation rather than relying on the test*() prefix.
Also no longer implement TestCase, to avoid triggering support for
the junit3-way, which stops the annotations from working.
Change the imports from import junit.framework.* to
import org.junit.*, which is apparently the new way.

10 years agoAdded a test for ListPlace token parsing and creation.
Murray Cumming [Sat, 31 Dec 2011 20:28:49 +0000 (21:28 +0100)]
Added a test for ListPlace token parsing and creation.

* src/test/java/org/glom/web/client/place/ListPlaceTest.java:
This is much the same as DetailsPlaceTest.

I wonder how we could test the other parts of the *Place API

10 years agowhitespace cleanup
Murray Cumming [Fri, 30 Dec 2011 22:34:26 +0000 (23:34 +0100)]
whitespace cleanup

10 years agoDetailsPlace test: Also test getToken() and recreation via getPlace().
Murray Cumming [Fri, 30 Dec 2011 22:27:09 +0000 (23:27 +0100)]
DetailsPlace test: Also test getToken() and recreation via getPlace().

* src/test/java/org/glom/web/client/place/DetailsPlaceTest.java:
testGetPlaceParameters(): Get the tokens from the DetailsPlace and
recreate it, testing the recreated DetailsPlace for the same parameter
values.

10 years agoUse the surefire-report plugin.
Murray Cumming [Fri, 30 Dec 2011 22:13:50 +0000 (23:13 +0100)]
Use the surefire-report plugin.

* pom.xml: This generates a HTML report about the tests in
target/site/surefire-report.html
when you do mvn surefire-report:report. It seems to be popular/normal.

10 years agoAdded a test for DetailsPlace.
Murray Cumming [Fri, 30 Dec 2011 22:12:14 +0000 (23:12 +0100)]
Added a test for DetailsPlace.

* src/test/java/org/glom/web/client/place/DetailsPlaceTest.java:
Test the getPlace() token parsing.

10 years agoAdded a first unit test.
Murray Cumming [Fri, 30 Dec 2011 14:01:07 +0000 (15:01 +0100)]
Added a first unit test.

* pom.xml: Add a test goal, and a dependency on junit in that scope.
* src/test/java/org/glom/web/shared/DataItemTest.java:
This is a silly test but it is just to get things started. Note that
maven/junit finds the test because it looks in src/test by default.

10 years agoUpdate a URL in a comment
Murray Cumming [Fri, 30 Dec 2011 13:26:03 +0000 (14:26 +0100)]
Update a URL in a comment

10 years agoUpdate a URL in a comment
Murray Cumming [Fri, 30 Dec 2011 13:25:54 +0000 (14:25 +0100)]
Update a URL in a comment

10 years agoChange charsetName to "UTF-8" when replacing line breaks.
Ben Konrath [Thu, 22 Dec 2011 22:37:34 +0000 (23:37 +0100)]
Change charsetName to "UTF-8" when replacing line breaks.

JavaScript requires the charsetName to be "UTF-8". CharsetName values
that work in Java (such as "UTF8") will not work when compiled to
JavaScript.

This fixes a problem with multi-line details view fields that have hard
line breaks. The "License Text" field on this page demonstrates the
problem:

http://onlineglom.openismus.com/OnlineGlom/#details:document=debian_repository_analyzer&table=licenses&value=197

* src/main/java/org/glom/web/client/ui/details/DetailsCell.java:

10 years agoFix another bug with related list navigation.
Ben Konrath [Thu, 22 Dec 2011 22:20:27 +0000 (23:20 +0100)]
Fix another bug with related list navigation.

I've tested all the navigation buttons in all of the related lists
so things should be good now.

* src/main/java/org/glom/web/server/ConfiguredDocument.java:

10 years agoFix a crasher when refreshing the list view with the default table.
Ben Konrath [Thu, 22 Dec 2011 14:05:04 +0000 (15:05 +0100)]
Fix a crasher when refreshing the list view with the default table.

This crash will also happen when loading the list view with the default
table from a link or bookmark.

* src/main/java/org/glom/web/client/activity/DetailsActivity.java: Go
to the main document selection page when the document id hasn't been
set.
* src/main/java/org/glom/web/client/activity/ListActivity.java: Go to
the main document selection page when the document id hasn't been
set.
* src/main/java/org/glom/web/client/place/DetailsPlace.java: Use empty
values for the details place when the document id hasn't been set.
* src/main/java/org/glom/web/client/place/ListPlace.java: Use empty
values for the list place when the document id hasn't been set.

10 years agoProtect against NPE when glom.document.locale is not in config.
Ben Konrath [Wed, 21 Dec 2011 17:23:07 +0000 (18:23 +0100)]
Protect against NPE when glom.document.locale is not in config.

This patch protects against an NPE when glom.document.locale is not in
the config file. This NPE will also happen if glom.document.locale is
commented out.

The patch also updates the error message to display the class name when
the getMessage() returns null. This was happening when the NPE was
thrown and I had "Configuration Error: null". If an NPE is encountered
with this patch, "Configuration Error: NullPointerException " will be
displayed.

This commit closes this bug:

https://bugzilla.gnome.org/show_bug.cgi?id=666669

* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:

10 years agoRename onlineglom.properties to onlineglom.properties.sample.
Murray Cumming [Tue, 20 Dec 2011 09:12:14 +0000 (10:12 +0100)]
Rename onlineglom.properties to onlineglom.properties.sample.

* src/main/resources/onlineglom.properties: Rename to:
* src/main/resources/onlineglom.properties.sample:
* src/main/resources/README: And add this file explaining that people
should rename it back when deploying.

10 years agoAllow choosing the translation in the .properties file.
Murray Cumming [Tue, 20 Dec 2011 08:56:21 +0000 (09:56 +0100)]
Allow choosing the translation in the .properties file.

* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
init(): Read a glom.document.locale value from the configuration file
and call Glom's TransatableItem::set_current_locale() method.
* src/main/resources/onlineglom.properties: Add a commented-out
example of this new setting.

It would be better to add &lang=de_DE to the URL, but the current
libglom API does not allow us to do this easily. I am working on that.

10 years agoRevert unwanted change.
Murray Cumming [Tue, 20 Dec 2011 08:11:25 +0000 (09:11 +0100)]
Revert unwanted change.

10 years agoAvoid a crash in parsing of token parameters.
Murray Cumming [Mon, 19 Dec 2011 18:20:26 +0000 (19:20 +0100)]
Avoid a crash in parsing of token parameters.

* src/main/java/org/glom/web/client/place/HasSelectableTablePlace.j
ava: getTokenParams(): Do not crash if a parameter has a key but no
value, and ignore parameters with neither.

10 years agoHistory token building/handling: Improve use of token parameters.
Murray Cumming [Sat, 17 Dec 2011 22:23:58 +0000 (23:23 +0100)]
History token building/handling: Improve use of token parameters.

* src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
(HasSelectableTablePlace.Tokenizer): Add getTokenParams(String)
and buildParamsToken(HashMap), for use by derived classes.
Make the separator private because it is no longer be needed.
* src/main/java/org/glom/web/client/place/DetailsPlace.java
(DetailsPlace.Tokenizer.getToken): Use buildParamsToken()
instead of manual string concatenation.
(DetailsPlace.Tokenizer.getPlace): Use getTokenParams() instead
of hardcoded indices and awkward splitting code.
* src/main/java/org/glom/web/client/place/ListPlace.java
(ListPlace.Tokenizer.getToken): Use buildParamsToken()
instead of manual string concatenation.
(ListPlace.Tokenizer.getPlace): Use getTokenParams() instead
of hardcoded indices and awkward splitting code.
This should fix bug #666420

10 years agoUpdate a URL in a comment
Murray Cumming [Sat, 17 Dec 2011 12:40:32 +0000 (13:40 +0100)]
Update a URL in a comment

10 years agoFix a Navgiation->Navigation typo in the code.
Murray Cumming [Fri, 16 Dec 2011 20:39:42 +0000 (21:39 +0100)]
Fix a Navgiation->Navigation typo in the code.

* src/main/java/org/glom/web/client/activity/DetailsActivity.java
Rename processNavgiation() to processNavigation().

10 years agoFix a seperator->separator typo in the code.
Murray Cumming [Fri, 16 Dec 2011 19:41:28 +0000 (20:41 +0100)]
Fix a seperator->separator typo in the code.

* src/main/java/org/glom/web/client/place/DetailsPlace.java
* src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
* src/main/java/org/glom/web/client/place/ListPlace.java: Just a
misspelling.

10 years agoCleanup some comments.
Ben Konrath [Thu, 15 Dec 2011 13:50:32 +0000 (14:50 +0100)]
Cleanup some comments.

* src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:

10 years agoReplace \n with <br/> for multiline text in the details view.
Ben Konrath [Wed, 14 Dec 2011 16:28:03 +0000 (17:28 +0100)]
Replace \n with <br/> for multiline text in the details view.

Vertical scrollbars are added when needed as well.

* src/main/java/org/glom/web/client/ui/details/DetailsCell.java:

10 years agoSpecify the font for document selection links.
Ben Konrath [Wed, 14 Dec 2011 11:21:28 +0000 (12:21 +0100)]
Specify the font for document selection links.

* src/main/webapp/style.css:

10 years agoFix bouncy CellTable while paging.
Ben Konrath [Wed, 14 Dec 2011 10:45:31 +0000 (11:45 +0100)]
Fix bouncy CellTable while paging.

This doesn't currently work with related list tables in unselected
Notebook tabs.

* src/main/java/org/glom/web/client/ui/list/ListTable.java

10 years agoRevamp the appearance of the document selection page.
Ben Konrath [Wed, 14 Dec 2011 10:01:20 +0000 (11:01 +0100)]
Revamp the appearance of the document selection page.

* src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java:
* src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.ui.xml:
* src/main/webapp/style.css:

10 years agoSet navigation button column to the smallest size possible.
Ben Konrath [Tue, 13 Dec 2011 19:34:36 +0000 (20:34 +0100)]
Set navigation button column to the smallest size possible.

* src/main/java/org/glom/web/client/ui/list/ListTable.java:

10 years agoChange OpenButton nomenclature to NavigationButton.
Ben Konrath [Tue, 13 Dec 2011 09:22:43 +0000 (10:22 +0100)]
Change OpenButton nomenclature to NavigationButton.

Using NavigtionButton makes things more generic. Classes, methods and
variables have been changed.

This is a rename-only refactor.

* src/main/java/org/glom/web/client/activity/DetailsActivity.java:
* src/main/java/org/glom/web/client/ui/ListViewImpl.java:
* src/main/java/org/glom/web/client/ui/cell/NavigationButtonCell.java:
Renamed from OpenButtonCell.
* src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
* src/main/java/org/glom/web/client/ui/list/ListTable.java:
* src/main/java/org/glom/web/client/ui/list/ListViewTable.java:

10 years agoRemove unnecessary String argument in RelatedListTable and ListViewTable.
Ben Konrath [Mon, 12 Dec 2011 20:08:40 +0000 (21:08 +0100)]
Remove unnecessary String argument in RelatedListTable and ListViewTable.

* src/main/java/org/glom/web/client/activity/DetailsActivity.java:
* src/main/java/org/glom/web/client/ui/ListViewImpl.java:
* src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
* src/main/java/org/glom/web/client/ui/list/ListViewTable.java: