2012-01-20 Murray Cumming Build a source tarball with mvn assembly:single * assembly.xml: Add this file. * pom.xml: Use the maven-assembly-plugin and tell it to use our assembly.xml file. 2012-01-19 Murray Cumming 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. 2012-01-19 Murray Cumming README: Mention that you must install java-libglom packages separately. But then it works, because java-libglom is now in the central maven repository. 2012-01-18 Murray Cumming 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(). 2012-01-18 Murray Cumming 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. 2012-01-18 Murray Cumming 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.) 2012-01-18 Murray Cumming 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. 2012-01-18 Murray Cumming 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. 2012-01-18 Murray Cumming 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. 2012-01-17 Murray Cumming 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. 2012-01-17 Murray Cumming 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(). 2012-01-17 Murray Cumming 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. 2012-01-17 Murray Cumming 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. 2012-01-13 Murray Cumming Documents: Add some final keywords. * src/main/java/org/glom/web/shared/Documents.java: Eclipse suggested this. 2012-01-13 Murray Cumming 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. 2012-01-12 Murray Cumming 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/RelatedListDBAccess.ja va: getData(): Pass an empty string to getListData() for the quickFind parameter. 2012-01-12 Murray Cumming ListTable: Minor change. * src/main/java/org/glom/web/client/ui/list/ListTable.java createCellTable(): Make this protected instead of public. 2012-01-12 Murray Cumming Many files: Use final for the parameters and use the @override attribute. 2012-01-22 Ben Konrath Add anchor links for single line text that starts with http, ftp and www. Bug #667269 2012-01-22 Ben Konrath Add ellipsis to single line text in details view. Bug #667269 2012-01-04 Murray Cumming 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 2012-01-04 Murray Cumming Revert the COPYING.LESSER to COPYING rename. Apparently both should be there if it is LGPL. 2012-01-03 Murray Cumming *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. 2012-01-02 Murray Cumming 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. 2012-01-02 Murray Cumming 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++. 2012-01-02 Murray Cumming 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. 2012-01-02 Murray Cumming 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. 2011-01-02 Murray Cumming Use the latest java-libglom version. * pom.xml: Use java-libglom 1.19.2 instead of 1.19.1. 2012-01-01 Murray Cumming 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. 2012-01-01 Murray Cumming 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. 2012-01-01 Murray Cumming 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(). 2012-01-01 Murray Cumming 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. This test is run during mvn integration-test. 2011-12-31 Murray Cumming 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. 2011-12-31 Murray Cumming 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. 2011-12-30 Murray Cumming 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. 2011-12-30 Murray Cumming 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. 2011-12-30 Murray Cumming Added a test for DetailsPlace. * src/test/java/org/glom/web/client/place/DetailsPlaceTest.java: Test the getPlace() token parsing. 2011-12-30 Murray Cumming 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. 2011-12-22 Ben Konrath 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: 2011-12-22 Ben Konrath 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: 2011-12-22 Ben Konrath 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. 2011-12-21 Ben Konrath 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: 2011-12-20 Murray Cumming 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. 2011-12-20 Murray Cumming 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. 2011-12-19 Murray Cumming 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. 2011-12-17 Murray Cumming 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 2011-12-16 Murray Cumming Fix a Navgiation->Navigation typo in the code. * src/main/java/org/glom/web/client/activity/DetailsActivity.java Rename processNavgiation() to processNavigation(). 2011-12-16 Murray Cumming 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. 2011-12-15 Ben Konrath Cleanup some comments. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-12-14 Ben Konrath Replace \n with
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: 2011-12-14 Ben Konrath Specify the font for document selection links. * src/main/webapp/style.css: 2011-12-14 Ben Konrath 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 2011-12-14 Ben Konrath 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: 2011-12-13 Ben Konrath Set navigation button column to the smallest size possible. * src/main/java/org/glom/web/client/ui/list/ListTable.java: 2011-12-13 Ben Konrath 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: 2011-12-12 Ben Konrath 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: 2011-12-12 Ben Konrath Update variable names and comments. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: 2011-12-12 Ben Konrath Properly initialize numNonEmptyRows variable to zero. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: 2011-12-05 Ben Konrath Add latest mockup with HTML tables. Features of this mockup: -> HTML table for flowtable -> HTML table for flowtable column -> Example of how related lists would look -> Not using text entries for data items The current version of Online Glom doesn't use HTML tables for the flowtable columns. This mockup has been sent to the glom-devel mailing list but it's good to have it here as well. * mockups/details-view-html-tables.html: 2011-12-05 Ben Konrath Remove unnecessary getPrimaryKeyField() method. getPrimaryKeyFieldForTable(String) has been renamed to getPrimaryKeyField(String). * src/main/java/org/glom/web/server/database/DBAccess.java: * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: 2011-12-05 Ben Konrath Add string representation of TypedDataItem value to conversion error message. * src/main/java/org/glom/web/server/Utils.java: Logging the error message was extracted into its own method to avoid duplication. 2011-12-05 Ben Konrath Add type checking to navigation primary key value creation. Create navigation primary key only if the expected type from the Glom document matches the type returned by the SQL query. * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: 2011-12-05 Ben Konrath Rename a couple of variables in RelatedListNavigation. This is a rename-only refactor. * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: 2011-12-05 Ben Konrath Move getListLayoutGroup() into getListViewLayoutGroup(). This removes getListLayoutGroup(). It was only being called by getListViewLayoutGroup(). * src/main/java/org/glom/web/server/ConfiguredDocument.java: 2011-12-05 Ben Konrath Remove check for LayoutItem_Portal in list table method. This check is no longer necessary because the method isn't being used to create the LayoutItemPortal DTO. * src/main/java/org/glom/web/server/ConfiguredDocument.java: 2011-12-05 Ben Konrath Properly support related list navigation. Navigation from the "Repository Analyzer -> Package Scans -> Dependencies" related table wasn't working because the primary key for related tables wasn't being set properly. This commit fixes the problem. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Don't use getListLayoutGroup() to create the LayoutItemPortal DTO. This method doesn't set the primary key properly for related list tables. * src/main/java/org/glom/web/server/database/DBAccess.java: Add table name parameter to getPrimaryKeyLayoutItemField(). This makes the method useful for getting the primary key for list view tables and for related list tables. * src/main/java/org/glom/web/server/database/ListDBAccess.java: * src/main/java/org/glom/web/server/database/ListViewDBAccess.java: Move code to set the primary key for the table from the abstract ListDBAccess class to ListViewDBAccess as it's only correct for list view tables. * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: Properly add primary key to related list tables. 2011-12-02 Ben Konrath Properly set the horizontal alignment of fields. This fix is for both the list tables and the details view. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Use LayoutItem_WithFormatting.get_formatting_used_horizontal_alignment(boolean) to set the horizontal alignment of fields. 2011-12-02 Ben Konrath Display currency codes in the details view. * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: 2011-12-02 Ben Konrath Avoid duplicate JNI call. JNI is not as efficient as pure Java and this is an easy (and small) optimization. * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: Use previously retrieved value for whereClauseToTableName instead of getting it again. 2011-12-02 Ben Konrath Rename a couple of variables in RelatedListNavigation. This is a rename-only refactor. * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: 2011-12-02 Ben Konrath Indicate clearly that a mismatched primary key type is a bug. * src/main/java/org/glom/web/server/Utils.java: Change log level from warning to error. Add 'This is a bug.' to message. 2011-12-02 Ben Konrath Update / fix some comments. * src/main/java/org/glom/web/client/OnlineGlomService.java: Remove old comments. * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: Fix comment. * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: Fix comments. Add some TODOs. 2011-12-02 Ben Konrath Enable navigation to details view with string primary key from related list. * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: Create a text primary key value when return type of result is java.sql.Types.VARCHAR. 2011-12-02 Ben Konrath Use checkboxes for booleans in the details view. * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: 2011-12-01 Ben Konrath Improve performance of related list height calculation. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: Put code to calculate the expected height in a static initializer so that that it's only called once. 2011-12-01 Ben Konrath Show related list tables in notebooks (again). Calculate the height of the related list tables so the Notebook can be set the correct height. The height of the related list table is also needed by FlowTable to be able decide how to create the layout. * src/main/java/org/glom/web/client/ui/details/Portal.java: Calculate and set the Portal height based on the height of the related list table and the Portal container. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: Add method to calculate the height of the related list tables. * src/main/java/org/glom/web/client/ui/list/ListTable.java: * src/main/webapp/style.css: Add css class for Pager. This is needed to calculate the height of the Pager widget. 2011-12-01 Ben Konrath Use CellTable API for table property instead of setting style on Element. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: 2011-12-01 Ben Konrath Make ListViewTable and RelatedListTable a consistent height. The tables are now a consistent height regardless of the contents of the table. A hidden button is added to empty rows to ensure that the height of these rows will match the height of rows with data. A navigation button column is now added to every table. The width of the navigation column is set to 0px when a RelatedListTable shouldn't have navigation buttons. This maintains the a consistent row height in tables that don't show the navigation buttons. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Hide navigation column when not needed. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Move method arguments for navigation button to constructor of ListViewTable. * src/main/java/org/glom/web/client/ui/cell/OpenButtonCell.java: Render hidden button for empty data rows. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: Add method arguments for navigation button to constructor. * src/main/java/org/glom/web/client/ui/list/ListTable.java: Always create navigation buttons. Add hideNavigationButtons() method. * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: Add method arguments for navigation button to constructor. 2011-12-01 Ben Konrath Use 'visibility: hidden' in Utils.getWidgetHeight(). This is better choice because hidden elements are invisible, don't respond to events and are not part of the tab order. They will, however, take up space which is required to be able to calculate the height of the widget. * src/main/java/org/glom/web/client/Utils.java: 2011-12-01 Ben Konrath Use Utils.getWidgetHeight() in FlowTable. * src/main/java/org/glom/web/client/Utils.java: Remove TODO item about this. * src/main/java/org/glom/web/client/ui/details/FlowTable.java: 2011-12-01 Ben Konrath Put the details css class name on the correct table column. * src/main/java/org/glom/web/client/ui/list/ListTable.java: 2011-11-30 Ben Konrath Update for java-libglom API change. The getters and setters on FieldFormatting and NumericFormat were changed to remove the 'M'. * src/main/java/org/glom/web/server/ConfiguredDocument.java: 2011-11-29 Ben Konrath Only allow RelatedListTables in Portals. * src/main/java/org/glom/web/client/ui/details/Portal.java: 2011-11-29 Ben Konrath Only create a contents panel for Portals when title is being set. * src/main/java/org/glom/web/client/ui/details/Portal.java: 2011-11-29 Ben Konrath Set TabLayoutPanel height based on calculated height its widgets. This is a potential fix for this bug: https://bugzilla.gnome.org/show_bug.cgi?id=665133 * src/main/java/org/glom/web/client/ui/details/Notebook.java: 2011-11-29 Ben Konrath Align details field labels and data with the Open buttons. * src/main/webapp/style.css: 2011-11-29 Ben Konrath Remove unnecessary
in the Notebook widget. * src/main/java/org/glom/web/client/ui/details/Group.java: Remove method to get container FlowPanel (
). * src/main/java/org/glom/web/client/ui/details/Notebook.java: Run the initWidget() method directly on the TabLayoutPanel widget instead of Group's container widget. 2011-11-29 Ben Konrath Don't add group titles for Portals in Notebooks. This reverts the previous patch and fixes a bug I introduced with commit b1753fd27bd2c4ea189c4c353e0ece92dcc66c2c . * src/main/java/org/glom/web/client/ui/details/Group.java: * src/main/java/org/glom/web/client/ui/details/Portal.java: 2011-11-28 Ben Konrath Remove unused boolean argument in Portal constructor. Just a code cleanup. * src/main/java/org/glom/web/client/ui/details/Group.java: * src/main/java/org/glom/web/client/ui/details/Portal.java: 2011-11-28 Ben Konrath Remove hack for glom 1.18 style glom files. * src/main/java/org/glom/web/client/ui/details/Group.java: * src/main/java/org/glom/web/client/ui/details/Notebook.java: * src/main/java/org/glom/web/client/ui/details/Portal.java: 2011-11-28 Ben Konrath Use Gda Value version of primary key to log result too large error. * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: 2011-11-28 Ben Konrath Don't use TypedDataItem.getText() for Unknown types from the URL. * src/main/java/org/glom/web/client/place/DetailsPlace.java: * src/main/java/org/glom/web/server/Utils.java: Use getUnknown() instead of getText(). * src/main/java/org/glom/web/shared/TypedDataItem.java: Add unknown String field and getUnknown() method. 2011-11-28 Ben Konrath Log an error message when the java-libglom .so is not present. The error message was being set in the exception but not logged. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-11-28 Ben Konrath Ignore LayoutItem_CalendarPortals. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Don't create the LayoutItemPortal DTO for LayoutItem_CanendarPortals. 2011-11-28 Ben Konrath Extract method for creating the LayoutItemPortal DTO. Just breaking the code up into smaller chunks. * src/main/java/org/glom/web/server/ConfiguredDocument.java: 2011-11-28 Ben Konrath Add TypedDataItem. This should have been added with the refactor. Oops! * src/main/java/org/glom/web/shared/TypedDataItem.java: 2011-11-28 Ben Konrath Create primary key value from URL string using type from Glom document. See this bug, comments 19 - 25: https://bugzilla.gnome.org/show_bug.cgi?id=662376#c19 * src/main/java/org/glom/web/client/place/DetailsPlace.java: Don't create a TypeDataItem for the primary key here when loading from a URL. Show the same string for the primary key value as was received from the URL string (when loading from a URL). * src/main/java/org/glom/web/server/Utils.java: Update method for creating the Gda Value from the TypeDataItem to properly deal with creating a Gda Value based on the Glom document type for the primary key value string when loading from a URL. * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: Update for changed method name. 2011-11-27 Ben Konrath Rename PrimaryKeyItem to TypedDataItem. The name PrimaryKeyItem suggests what the class should be used for. TypedDataItem is a neutral name that describes the class better. This is a rename-only refactor. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: * src/main/java/org/glom/web/client/Utils.java: * src/main/java/org/glom/web/client/activity/DetailsActivity.java: * src/main/java/org/glom/web/client/place/DetailsPlace.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/ListTable.java: * 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/Utils.java: * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: * src/main/java/org/glom/web/shared/NavigationRecord.java: 2011-11-25 Ben Konrath Improve Gda Value conversion from PrimaryKeyItem. The value from the PrimaryKeyItem is only used if its type match the type from the glom document. * src/main/java/org/glom/web/server/Utils.java: 2011-11-25 Ben Konrath Manually check if the java-liblgom .so is visible to the JVM. It seems that Tomcat has problems when a static initializer throws an exception. This check is done before the first method call into java-libglom so that execution doesn't continue if the .so is not found. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-11-25 Ben Konrath Improve browser configuration error messages. This fixes: https://bugzilla.gnome.org/show_bug.cgi?id=662792 * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Add getConfigurationErrorMessage() method. * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java: Get and display a specific configuration error message when no Glom documents are found. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Implement getConfigurationErrorMessage() method. Surround configuration code in the init() method with a try/catch block. This allows the errors to be caught while keeping the servlet available to retrieve the configuration error message. 2011-11-25 Ben Konrath Don't use Strings to hold primary key values. The primary key values are now held in a new data object (PrimaryKeyItem) that holds type information and the primary key value using the correct type. * 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: Use PrimaryKeyItem instead of String to hold the primary key value. * src/main/java/org/glom/web/client/Utils.java: Remove getKeyValueStringForQuery(). Add getPrimaryKeyItem() which creates a PrimaryKeyItem based on the GlomFieldType and the DataItem. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Use PrimaryKeyItem instead of String to hold the primary key value. Load document selection page when the documentID has not been set correctly. * src/main/java/org/glom/web/client/place/DetailsPlace.java: Re-work DetailsPlace -> URL and URL -> DetailsPlace conversion with PrimaryKeyItem. * src/main/java/org/glom/web/client/place/DocumentSelectionPlace.java: Return empty string for URL instead of "null". * 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/ListTable.java: * src/main/java/org/glom/web/server/ConfiguredDocument.java: Use PrimaryKeyItem instead of String to hold primary key values. * src/main/java/org/glom/web/server/Utils.java: New method to convert a PrimaryKeyValue to a Gda Value. * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: Replace temporary database access code that uses the PrimaryKeyValue to Gda Value conversion. * src/main/java/org/glom/web/shared/DataItem.java: Add comment. * src/main/java/org/glom/web/shared/NavigationRecord.java: Use PrimaryKeyItem instead of String. * src/main/java/org/glom/web/shared/PrimaryKeyItem.java: New class to hold primary key values. 2011-11-24 Ben Konrath Use newly added java-libglom API to create queries. This isn't finished. I still need to stop using Strings for primary key values in the client code. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Tell libglom to use fake connections so that retrieving the query string will work. * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: * src/main/java/org/glom/web/server/database/ListViewDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: Use the newly added libglom sql methods and classes to create the query. Add temporary hack to convert primary value strings to Gda Value. 2011-11-23 Ben Konrath Don't explicitly set the height of Portals. See comments 6 - 10 of this bug for details: https://bugzilla.gnome.org/show_bug.cgi?id=662930#c6 * src/main/java/org/glom/web/client/ui/details/Portal.java: 2011-11-23 Ben Konrath Use an HTML table instead of CSS for the FlowTable layout. * src/main/java/org/glom/web/client/ui/details/FlowTable.java: Use GWT's FlexTable to implement the FlowTable. * src/main/webapp/style.css: Adjust CSS for the change to FlexTable. 2011-11-18 Ben Konrath Add boolean example to HTML table mockup. * mockups/details-view-html-tables-text-entries.html: 2011-11-17 Ben Konrath Ensure the pager buttons are always visible for related lists. To accomplish this, I've turned off text wrapping in the list view and related list tables for both the header and data text. The related list table now has a fixed layout so the it doesn't overflow its container. This is required to ensure that the cell text is clipped when it overflows the cell and an ellipsis is added to the right side of the cell when text is clipped. A fixed table layout for the related list table in the details view seems what we want for the details view anyway, so the side-effect is desirable. The ellipsis will only be displayed in Firefox >= 7. This fixes bug: https://bugzilla.gnome.org/show_bug.cgi?id=662930 * src/main/java/org/glom/web/client/ui/cell/NumericCell.java: * src/main/java/org/glom/web/client/ui/cell/TextCell.java: Add 'overflow: hidden; text-overflow: ellipsis;' CSS properties to the table cell text. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: Set the 'table-layout: fixed' CSS property to the related list table. * src/main/java/org/glom/web/client/ui/list/ListTable.java: Set the 'white-space: nowrap;' CSS property on both the list view and the related list tables. 2011-11-16 Ben Konrath Rework the fix for empty notebook tab labels. Setting the empty group titles with its name caused problems for the details layout. Instead of using libglom's LayoutItem.get_title_or_name(), the LayoutItem name is explicitly sent to the client when the title is empty. This allows the Notebook to use the name when the title is empty without affecting anything else. * src/main/java/org/glom/web/client/ui/details/Notebook.java: * src/main/java/org/glom/web/server/ConfiguredDocument.java: 2011-11-16 Ben Konrath Set group titles with name when title is empty. This fixes a problem with an empty notebook tab label in the Lesson Planner document. The forth tab in the notebook should be "Internet": http://bagu.org:8080/OnlineGlom/#details:document=lesson-planner&table=teachers&value=0 * src/main/java/org/glom/web/server/ConfiguredDocument.java: Use libglom's LayoutItem.get_title_or_name() to fill in the LayoutGroup DTO title. 2011-11-16 Ben Konrath Remove whitespace from the configured username properties. This assumes that usernames won't have whitespace at the beginning or end. But I think this is a reasonable assumption. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Use String.trim() to remove the whitespace from the username properties. 2011-11-15 Ben Konrath Add details view mockup with HTML tables and text entries. This is from the attachment on this bug: https://bugzilla.gnome.org/show_bug.cgi?id=663109 * mockups/details-view-html-tables-text-entries.html: 2011-11-15 Ben Konrath Add space between the columns of the flow table. This fixes: https://bugzilla.gnome.org/show_bug.cgi?id=662918 * src/main/java/org/glom/web/client/ui/details/FlowTable.java: Add a 1% space between columns in the flow table. 2011-11-15 Ben Konrath Add backup files to the .gitignore. * .gitignore: Ignore files that end with ~. 2011-11-09 Ben Konrath Use latest release of gwt-log. Gwt-log releases are now being submitted to the maven central repository so manual installation of the jar is no longer required. * pom.xml: Update version and groupId of gwt-log dependency. 2011-10-31 Ben Konrath Don't use GWT numeric formatting to override the glom currency formatting. Currencies are now displayed like they are in Glom. See this bug: https://bugzilla.gnome.org/show_bug.cgi?id=646216 * src/main/java/org/glom/web/client/Utils.java: Remove GWT currency formatting. * src/main/java/org/glom/web/client/ui/cell/NumericCell.java: Add currency code to constructor and set it when the cell is rendered. * src/main/java/org/glom/web/client/ui/list/ListTable.java: Add the currency code to the constructor of the NumericCell. 2011-10-27 Ben Konrath Require the latest release of java-libglom (1.17.4). * pom.xml: 2011-10-26 Ben Konrath Add style to Notebook that matches current theme. It's not the best style in the world but it's better than the default. * src/main/java/org/glom/web/client/ui/details/Notebook.java: Add some padding at the bottom of the child widgets. * src/main/webapp/style.css: Add style for the Notebook. 2011-10-26 Ben Konrath Move servlet initialization code to overridden init method. This is half of the solution to getting proper error messages displayed when configuration errors occur. Here's the relevant bug: https://bugzilla.gnome.org/show_bug.cgi?id=662792 The rest of the solution involves surrounding the init method with a try/catch block and setting a global variable with the error / exception. A new async method should be created to retrieve and display the error message / exception. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Move code from constructor to init method adding exceptions as needed. 2011-10-26 Ben Konrath Add script to monitor and restart tomcat if required. * utils/check-and-recover-tomcat.py: New file. 2011-10-26 Ben Konrath Display the correct number of data items in the pager. This commit fixes: https://bugzilla.gnome.org/show_bug.cgi?id=661441 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: The implementation is the same for both tables: Keep track of the number of non-empty rows and fire and RowCountChangeEvent after the data has been updated. * src/main/java/org/glom/web/client/ui/list/ListTable.java: Add a custom Pager class that subclasses SimplePager to handle displaying the correct number when empty rows have been added. 2011-10-26 Ben Konrath Correct error in previous commit. * src/main/java/org/glom/web/client/activity/ListActivity.java: Remove eventBus parameter from listView.setCellTable(). 2011-10-26 Ben Konrath Fix error in TODO comment. * src/main/java/org/glom/web/client/activity/ListActivity.java: 2011-10-24 Ben Konrath Create Notebook widgets to the details view. This isn't finished just yet - I still need to create a reasonable style to match the current theme. * src/main/java/org/glom/web/client/Utils.java: Add method for calculating the height of a widget. This is used in the Notebook class. * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Update for new constructor method in Group. * src/main/java/org/glom/web/client/ui/details/Group.java: Add new method for creating child widget that can be used by subclasses like Notebook. New constructor that allows disabling the group titles - Notebooks don't set a group title for their child groups. * src/main/java/org/glom/web/client/ui/details/Notebook.java: New class to make Notebooks using GWT's TabLayoutPanel. * src/main/java/org/glom/web/client/ui/details/Portal.java: New constructor that allows disabling the group titles. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Create the LayoutItemNotebook DTO. * src/main/java/org/glom/web/shared/layout/LayoutItemNotebook.java: New DTO for Notebooks. It's just an empty class for now but we might need it to transfer some specific information in the future. 2011-10-21 Ben Konrath Add navigation buttons to related list tables. * 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: Add new method getSuitableRecordToViewDetails() for getting the table name and primary key value for related list navigation buttons. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Add private cell renderer class to get the navigation information for related list tables from the server. Extract the navigation processing code from the details cell navigation and use it for the related list navigation as well. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Add private cell renderer class for the details open buttons. This was needed because the related list navigation buttons and the list view navigation buttons need to react differently when clicked. * src/main/java/org/glom/web/client/ui/cell/OpenButtonCell.java: Remove the onEnterKeyDown() method because it's now overriden in the subclasses that are specific to the related list tables and the list view tables. * src/main/java/org/glom/web/client/ui/details/Portal.java: Increase the vertical size a little because the buttons add a bit of vertical space to table. This is not a perfect solution because the vertical size of with table fewer than 5 rows will be a little smaller. * src/main/java/org/glom/web/client/ui/list/ListTable.java: Update for changes in how navigation buttons are handled. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Implement getSuitableRecordToViewDetails() using the new RelatedListNavigation database access object. * src/main/java/org/glom/web/server/database/DBAccess.java: Move code to find the portal for a given relationship name from RelatedListDBAccess. Add method to find a primary key field for a given table. * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: Move code to find the portal for a given relationship name to DBAccess. * src/main/java/org/glom/web/server/database/RelatedListNavigation.java: New file: database access object for getting the related list navigation information (the table name and the primary key value). * src/main/java/org/glom/web/shared/NavigationRecord.java: New file: DTO for transferring a table name to navigate to and a primary key value. * src/main/java/org/glom/web/shared/layout/LayoutItemPortal.java: Add boolean and getter/setter to specifies if the related list should add navigation buttons. 2011-10-24 Murray Cumming Use the master branch of java-libglom * pom.xml: Depend on java-libglom 1.19 instead. This is the master branch. See also the libglom-1-18 branch. 2011-10-11 Ben Konrath Enable the open navigation button when the data has been set. This avoids having active buttons that don't do anything when the data has not been set. * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: 2011-10-11 Ben Konrath Use IsWidget interface for FlowTableItem. * src/main/java/org/glom/web/client/ui/details/FlowTable.java: Change FlowTableItem.getWidget() to asWidget() from the IsWidget interface. 2011-10-11 Ben Konrath Remove GWT styling from open button in details view. There are still some issues with how the details cell is arranged but this should be made to match Glom 1.20. I'm going to leave fixing this until I have Glom 1.20 up and running. * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: Set style name on open button. * src/main/webapp/style.css: Move and edit details-navigation class. Re-arrange some classes to make them appear in the same order as the UI. 2011-10-07 Ben Konrath Update to GWT 2.4.0. * .gitignore: Ignore new cache directory. * .settings/com.google.gwt.eclipse.core.prefs: Update Eclipse settting. * pom.xml: Change GWT and maven plugin to 2.4.0. * src/main/java/org/glom/web/OnlineGlom.gwt.xml: Update doctype for 2.4.0. * src/main/java/org/glom/web/client/ClientFactory.java: * src/main/java/org/glom/web/client/ClientFactoryImpl.java: * src/main/java/org/glom/web/client/OnlineGlom.java: Update source for API changes. * utils/build-onlineglom-war.sh: Remove cache directory before the build. 2011-10-07 Ben Konrath Add navigation buttons in the details view. This isn't finished but I thought I'd commit what I have as it's a pretty good start. I still need to: 1. Change the style so that it fits better into the current theme 2. Adjust the details cell to expand as much as possible. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Add click handlers to navigation buttons in the DetailsCells. Create a refreshData() method to get just the data from the server without the layout. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: Update the tableSelector and browser title when the table name changes without using the tableSelector. * src/main/java/org/glom/web/client/ui/DetailsView.java: * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Rename getDetailsCells() to getCells(). Update variable names. * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: Add method to set click handler on navigation button. Rename a few variables. Add navigation buttons where needed. * src/main/java/org/glom/web/client/ui/details/Group.java: Rename a few variables and methods. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Set the navigation boolean and navigation table as required in the LayoutItemField DTO. * src/main/java/org/glom/web/shared/layout/LayoutItemField.java: Add variables for navigation along with getter/setter methods. 2011-10-07 Ben Konrath Rename Field to DetailsCell. This is a refactor-only commit. No functionality has been added or removed. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Update variable and method names. * src/main/java/org/glom/web/client/ui/DetailsView.java: * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Update variable and method names. * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: Renamed from Field. * src/main/java/org/glom/web/client/ui/details/Group.java: Update variable and method names. 2011-10-07 Ben Konrath Create separate methods for layout and data the details view. This is a refactor-only commit. No functionality has been added or removed. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: New private methods: setData(), createLayout(). 2011-10-07 Ben Konrath Don't use TableSelectorImpl implementation details in TableSelectorActivity. This is part of a change to get navigation buttons in the details view but it should have been done this way from the start. * src/main/java/org/glom/web/client/activity/ListActivity.java: Update for method name change in TableSelectionView. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: Create TableChangeEvent and set the browser title using the TableSelectionView API. * src/main/java/org/glom/web/client/ui/TableSelectionView.java: * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java: Change getSelectedTable() to getSelectedTableName(). Add getSelectedTableTitle(). 2011-10-07 Ben Konrath Use primaryKeyValue naming convention in constructor of DetailsPlace. * src/main/java/org/glom/web/client/place/DetailsPlace.java: 2011-10-07 Ben Konrath Update TableChangeEvent to use newTableName naming convention. This makes the class more consistent with GWT naming conventions. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Update for method name change in TableChangeEvent. * src/main/java/org/glom/web/client/activity/ListActivity.java: Update for method name change in TableChangeEvent. * src/main/java/org/glom/web/client/event/TableChangeEvent.java: Update newTableName variable and getter method. Make toDebugString() actually work. 2011-09-30 Ben Konrath Disable the pager in the list tables when the data row count is less than the minimum. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: * src/main/java/org/glom/web/client/ui/ListViewImpl.java: 2011-09-30 Ben Konrath Add empty rows to the end of related list and list view tables. I also extracted the cell rendering classes from the ListTable because the code was becoming a little crazy with all the anonymous inner classes. My plan is to use these cell rendering classes in the details view as well so this refactor will be needed for that change. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Only set the row count in related list tables if the data has more rows than the minimum number of rows visible. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Only set the row count in list view tables if the data has more rows than the minimum number of rows visible. * src/main/java/org/glom/web/client/ui/cell/BooleanCell.java: New class for rendering TYPE_BOOLEAN cells. The code was extracted from the ListTable class. * src/main/java/org/glom/web/client/ui/cell/NumericCell.java: New class for rendering TYPE_NUMERIC cells. The code was extracted from the ListTable class. * src/main/java/org/glom/web/client/ui/cell/OpenButtonCell.java: New class for rendering cells with buttons in list views. The code was extracted from the ListTable class. * src/main/java/org/glom/web/client/ui/cell/TextCell.java: New class for rendering TYPE_TEXT cells. The code was extracted from the ListTable class. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: Add empty rows to the end of the data if required. Implement ListTable.getMinNumVisibleRows(). * src/main/java/org/glom/web/client/ui/list/ListTable.java: Extract cell renderer code to public classes. Return null in Column.getValue() for empty rows. Add new abstract method: getMinNumVisibleRows(). Move code to set the row count of the list view table to ListViewImpl. * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: Add empty rows to the end of the data if required. Implement ListTable.getMinNumVisibleRows(). 2011-09-27 Ben Konrath Use GWT.log for client-side debugging statements. These are optimized out when deployed so I should have used this method in the first place. These statements will eventually be replaced with some sort of notification in the browser. * 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/ui/details/RelatedListTable.java: * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: 2011-09-27 Ben Konrath Put tableselector on the right, back to list link on right. The idea is that the table selector is acting like a label for the currently displayed table so it should be placed below the document title. This puts the table title in a similar position to where it is in Glom. * mockups/details-contacts.html: * mockups/details-projects.html: * mockups/listview-contacts.html: * mockups/listview-projects.html: * mockups/style.css: Update mockups to match how the interfaces currently look. * src/main/webapp/style.css: Swap positions of backlink with the table selector. Add some space on the left side of the table selector to line things up with the document title. 2011-09-27 Ben Konrath Add field colouring to details view. This change re-works how field colouring works. The colour formatting information is now set to the client with the layout information instead of with the data. This eliminates the need to send the same colour strings for data in list view column when colour information is set. In order to set an alternate colour for negative numeric values, the number is now sent to client and formatted with the GWT NumberFormat class. This change also fixes: https://bugzilla.gnome.org/show_bug.cgi?id=659752 * src/main/java/org/glom/web/OnlineGlom.gwt.xml: Add the GWT internationalization framework which is needed for client side numeric formatting. * src/main/java/org/glom/web/client/Utils.java: New file for some client static utility methods. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Pass the DataItem object to the Field class. Use a utility method to create the foreignKeyValue string. * src/main/java/org/glom/web/client/ui/details/Field.java: Set alignment and text colours in the constructor. Add setData(DataItem) method. Remove setText(String) method. * src/main/java/org/glom/web/client/ui/list/ListTable.java: Add the colour information to GlomTextCell. Create and use GlomNumberCell for rendering numbers. Use utility method to get the string for the primary key of the key provider. Re-work how the horizontal alignment is set. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Add formatting to layout information. Methods for converting the libglom formatting information were moved from DBAccess. * src/main/java/org/glom/web/server/database/DBAccess.java: Remove numeric formatting (it's now done on the client side). Don't set text colours in DataItem. Move libglom formatting conversion methods to ConfiguredDocument. * src/main/java/org/glom/web/shared/DataItem.java: Remove fields and getters/setters for text colour information. * src/main/java/org/glom/web/shared/GlomNumericFormat.java: New file for transferring the libglom NumericFormat information to the client. * src/main/java/org/glom/web/shared/layout/Formatting.java: Add fields and getters/setters for: GlomNumericFormat, background colour and foreground colour strings. 2011-09-26 Ben Konrath Simplify code that iterates through the LayoutGroup. * src/main/java/org/glom/web/client/ui/list/ListTable.java: 2011-09-26 Ben Konrath Accept Eclipse formatting for OnlineGlomServiceAsync. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: 2011-09-26 Ben Konrath Don't use the ListDBAccess classes to get the primary key layout information. This was causing a bug where the wrong index for the hidden primary key was being sent to the client. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Find the primary key while creating the LayoutGroup DTO. Create a LayoutItemField DTO for hidden primary keys. Don't use the RelatedListDBAccess because it was only used for getting the primary key. * src/main/java/org/glom/web/server/database/DBAccess.java: Change the access modifier from public to protected for getPrimaryKeyField() and getPrimaryKeyLayoutItemField(). * src/main/java/org/glom/web/server/database/ListDBAccess.java: Remove abstract method getExpectedResultSize() because RelatedListDBAccess doesn't have enough info to implement it. * src/main/java/org/glom/web/server/database/ListViewDBAccess.java: Remove @Override for getExpectedResultSize(). * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: Remove method getExpectedResultSize(). 2011-09-23 Ben Konrath Log which layout (list or details) the ignored item is from. * src/main/java/org/glom/web/server/ConfiguredDocument.java: 2011-09-23 Ben Konrath Remove annotations that turn off code formatting in DataItem. * src/main/java/org/glom/web/shared/DataItem.java: 2011-09-23 Ben Konrath Rename GlomField to DataItem and update associated methods. This is a rename-only refactor. No functionality has been added or removed. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: * 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/ListTable.java: * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: * 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/DBAccess.java: * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: * src/main/java/org/glom/web/server/database/ListDBAccess.java: * src/main/java/org/glom/web/server/database/ListViewDBAccess.java: * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: * src/main/java/org/glom/web/shared/DataItem.java: * src/main/java/org/glom/web/shared/DetailsLayoutAndData.java: * src/main/java/org/glom/web/shared/layout/LayoutGroup.java: 2011-09-23 Ben Konrath Rename GlomDocument to DocumentInfo and update associated methods. This is a rename-only refactor. No functionality has been added or removed. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.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/server/ConfiguredDocument.java: * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: * src/main/java/org/glom/web/shared/DocumentInfo.java: 2011-09-20 Ben Konrath Require java-libglom 1.17.3. This picks up the fix for the seg fault problem with the Scenes table in the Openismus Film Manager example. * pom.xml: 2011-09-20 Ben Konrath Change the way sort clause is added for primary key when no sort clause is requested. The primary key is now added to the LayoutFieldVector (fieldsToGet) before the sort clause is created. When a sort clause is not requested, the sort clause is created by finding the primary key in the LayoutFieldVector (fieldsToGet). * src/main/java/org/glom/web/server/database/ListDBAccess.java: 2011-09-20 Ben Konrath Log error message if no documents are found in the configured directory. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Also: Extract the glom file extension string to a private static final class variable (mostly as syntactic sugar). Accept a minor formatting change. * src/main/resources/onlineglom.properties: Add '/glomfile' to end of the example glom.document.directory configuration property to make it more clear that it can any directory, not just the home directory. 2011-09-18 Ben Konrath Add related lists to details view. The related list table has support for paging and sorting just like the table in the list view. * pom.xml: Require java-libglom 1.17.2 for the new methods to build the SQL queries for the related list tables. * 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: Rename getList methods to getListView and add comments. Remove getDetailsLayout() as it's not used anymore. Add note to getDetailsData() about it being unused. Add methods: getDetailsLayoutAndData(), getSortedRelatedListData(), getRelatedListData(), getRelatedListRowCount() * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Create the layout and set the data for the fields in one async call instead of two. Create related lists where appropriate. * src/main/java/org/glom/web/client/activity/ListActivity.java: Changes for method name changes in OnlineGlomService. * src/main/java/org/glom/web/client/ui/DetailsView.java: * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Rename addLayoutGroup() to addGroup(). Add methods to get the DTOs for the visible UI objects. * src/main/java/org/glom/web/client/ui/ListView.java: * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Remove tableName from setCellTable(). Create a ListViewTable instead of ListTable. * src/main/java/org/glom/web/client/ui/details/Field.java: New class to represent a data field in the details view. * src/main/java/org/glom/web/client/ui/details/Group.java: Move to code from addDetailsCell() to Field class. Keep track of the Fields and Portals in the details view. * src/main/java/org/glom/web/client/ui/details/Portal.java: Make portal a little bigger to match Glom. Keep track of the LayoutItemPortal DTO and add a method to get it. Add method to set the contents of the portal. * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: New class for related list tables. This class has the data provider for the related list table. * src/main/java/org/glom/web/client/ui/list/ListTable.java: Change to abstract class which is the base class for the ListViewTable and the RelatedListTable. * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: New class for list view tables. This class has the data provider for the list view table. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Add methods for related list tables. Add more information to the LayoutItemField and LayoutItemPortal DTOs. * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: Remove debugging print statement. * src/main/java/org/glom/web/server/database/ListDBAccess.java: Remove debugging print statements. Add primary key field to SQL count query. * src/main/java/org/glom/web/server/database/ListViewDBAccess.java: Remove unnecessary LayoutFieldVector parameter from getResultSizeOfSQLQuery() method. * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java: New class for related list table database access. * src/main/java/org/glom/web/shared/DetailsLayoutAndData.java: New class that is a wrapper DTO for details view layout and data. * src/main/java/org/glom/web/shared/layout/LayoutItemPortal.java: Add new 'fromField' string to this DTO. * src/main/webapp/style.css: Remove bottom margin and override top margin with 0em. 2011-09-15 Ben Konrath Breakup the OnlineGlomServiceImpl class to make it more manageable. This sets things up to make it easier to add the data retrieval for related lists (portals). No user noticeable changes were made with this commit. * src/main/java/org/glom/web/server/ConfiguredDocument.java: This class has the code to retrieve the layouts and access the database using the new database helper classes. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Most of the functionality has been removed from this class. This class now represents the public interface for the client side code. It also deals with configuring the servlet and cleaning things up when the servlet is stopped. * src/main/java/org/glom/web/server/Utils.java: Extract a couple of static methods into this utility class. * src/main/java/org/glom/web/server/database/DBAccess.java: * src/main/java/org/glom/web/server/database/DetailsDBAccess.java: * src/main/java/org/glom/web/server/database/ListDBAccess.java: * src/main/java/org/glom/web/server/database/ListViewDBAccess.java: These classes have the database retrieval code. The class hierarchy has been setup to make it easy to reuse code for similar functionality. 2011-09-06 Ben Konrath Create separate classes for list table code and the data provider. As part of this refactor, I also split up the code a bit to make it more manageable. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Move list table code to two new classes (below). * src/main/java/org/glom/web/client/ui/list/ListTable.java: New file with code from ListViewImpl. * src/main/java/org/glom/web/client/ui/list/ListTableDataProvider.java: New file with code from ListViewImpl. 2011-09-06 Ben Konrath Change the LayoutItemPortal DTO to extend LayoutGroup instead of LayoutItem. This fixes the LayoutItemPortal DTO to match the libglom layout object hierarchy. * src/main/java/org/glom/web/shared/layout/LayoutItemPortal.java: 2011-09-01 Ben Konrath Set title of Portals in the Details View. * pom.xml: Bump required version of java-libglom to 1.17.1. * src/main/java/org/glom/web/client/ui/details/Group.java: Move Portal widget creation to its own class. Add comments to constructor. * src/main/java/org/glom/web/client/ui/details/Portal.java: New file. The code is mostly from the Group class with the title now set. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Set title of Portal. Update some comments. Fix some code formatting. 2011-09-01 Ben Konrath Remove TODO comment for the flow table column width. The flow table column width is working correctly and doesn't need to be changed. See this mailing list post for more info: https://mail.gnome.org/archives/glom-devel-list/2011-August/msg00017.html * src/main/java/org/glom/web/client/ui/details/FlowTable.java: 2011-08-27 Ben Konrath Add document title (database name) to top of the browser page. I added the document title to the TableSelecitonView but that will change if / when we add a view that doesn't require table selection. * mockups/details-contacts.html: * mockups/details-projects.html: * mockups/listview-contacts.html: * mockups/listview-projects.html: * mockups/style.css: Add document title to mockups to keep things consistent. * src/main/java/org/glom/web/client/OnlineGlom.java: Adjust LayoutPanel sizes to account for the document title. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: Set the document title when it has been retrieved from the server. * src/main/java/org/glom/web/client/ui/TableSelectionView.java: * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java: Add and implement setDocumentTitle(String) method. * src/main/webapp/style.css: Add ID for document title style. 2011-08-25 Ben Konrath Add NavigationType enum to LayoutItemPortal DTO. This is the start of adding support for Portals to the Details View. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Convert LayoutItem_Portal.navigation_type enum from libglom to LayoutItemPortal.NavigationType enum. * src/main/java/org/glom/web/shared/layout/LayoutItemPortal.java: Add NavigationType enum, field for storing the NavigationType and getter and setter methods. 2011-08-25 Ben Konrath Implement the flow table layout in the Details View. * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Change FlowTable to Group to account for the renamed class. * src/main/java/org/glom/web/client/ui/details/FlowTable.java: New File. This is a container widget that implements the Glom details view flow table behaviour. * src/main/java/org/glom/web/client/ui/details/Group.java: Moved from org/glom/web/client/ui/FlowTable.java. * src/main/webapp/style.css: Adjust bottom margin of the subgroup-title so that the size of the subgroups are a closer match to the size of the Glom subgroups. This makes the flowtable layout match the layout in Glom for the Music Collection example file. 2011-08-16 Ben Konrath Create container element for LayoutItemPortal in Details View. This will help me develop the layout for the FlowTable. * src/main/java/org/glom/web/client/ui/FlowTable.java: Also rename fieldPanel variable to detailsCell. 2011-08-15 Ben Konrath Set the height of the data element in the Details View. I changed the InlineLabels (text in a span element) to Labels (text in a div element) so that I could set the height of the details-data elements instead of the details-cell parent elements. This allows the the details-data element to display the correct height if style is applied that shows the height. This change has the added benefit of allowing the order of the labels and data elements to be changed for right-to-left languages. * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Change InlineLabels to Labels. * src/main/java/org/glom/web/client/ui/FlowTable.java: Change InlineLabels to Labels. Set the height of the data element. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Set the multiline text height in the Formatting DTO. * src/main/java/org/glom/web/shared/layout/Formatting.java: Add field for multiline height along with getter and setter methods. * src/main/webapp/style.css: Adjust style to account for the change from span elements to div elements in the details cell. 2011-08-15 Ben Konrath Make the List View appearance match the mockups. It doesn't match exactly but it's much better than it was. * mockups/listview-contacts.html: Remove unused css classes. * mockups/listview-projects.html: Remove unused css classes. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Display 15 rows instead of 20. Rename vPanel to mainPanel. Use FlowPanel (div) for mainPanel instead of VerticalPanel (table). Set style name on CellTable. Set style name on Details column. Right-align Details buttons. * src/main/webapp/style.css: Adjust properties to match the mockups. 2011-08-12 Ben Konrath Add better support for subgroups in the details view. * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Update for changed FlowTable constructor. * src/main/java/org/glom/web/client/ui/FlowTable.java: Add better support for subgroups and subgroup-titles. * src/main/webapp/style.css: Add CSS class for subgroups and subgroup-titles. 2011-08-12 Ben Konrath Return the top level LayoutGroup title. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-08-11 Ben Konrath Make the TableSelector header match the mockup. * src/main/java/org/glom/web/client/OnlineGlom.java: Add a margin to the layout panel. Properly lineup the table selection header with the list and details view. * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Remove the margin around the details view. * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java: Rename listBox variable to tableSelector. Set id for the style sheet. Use a FlowPanel instead of a HorizontalPanel. * src/main/webapp/style.css: Add properties to make the TableSelector box match the mockups. 2011-07-13 Ben Konrath Update install script for java-libglom version change. * utils/install-onlineglom-war.sh: Also exit if 'make check' in java-libglom fails. 2011-07-13 Ben Konrath Add support sub-group in the details view. I also removed the code that special-cased the default details view layout. See: http://mail.gnome.org/archives/glom-devel-list/2011-July/msg00005.html I still have to make a proper flowtable. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Don't special-case default details view layout. * src/main/java/org/glom/web/client/ui/DetailsView.java: Remove addLayoutField() as I'm going to use it. * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Extract GroupPanel to FlowTable class. Remove unimplemented addLayoutField() method. * src/main/java/org/glom/web/client/ui/FlowTable.java: New class extracted from DetailsViewImpl.GroupPanel. Add support for sub-groups. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Set column count when getting the details layout. 2011-07-12 Ben Konrath Set browser title with database and table titles. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: Set the browser title when the table changes and when the activity first starts. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Set title when retrieving document info (the GlomDocument object). * src/main/java/org/glom/web/shared/GlomDocument.java: Add title field with getter and setter methods. Remove unused convenience constructor. Use default code formatting. 2011-07-12 Ben Konrath Ignore LayoutItemPortals in the details view. I added a new DTO for the LayoutItemPortal so that I can ignore it in the client code. * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Ignore LayoutItemPortal layout objects. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Create LayoutItemPortal objects when retrieving the details layout. * src/main/java/org/glom/web/shared/layout/LayoutItemPortal.java: New file. This is an empty class and just used to get type information for now. 2011-07-12 Ben Konrath Use java-libglom 1.17.0. * pom.xml: 2011-07-11 Ben Konrath Remove "Table:" label from table selector. This matches a recent change in the Glom UI. * mockups/details-contacts.html: * mockups/details-projects.html: * mockups/listview-contacts.html: * mockups/listview-projects.html: Remove the "Table:" label from the mockups as well. * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java: 2011-07-11 Ben Konrath Add main groups to the details view. This makes things look a little nicer in the details view. The next step is to implement the flowtable. * src/main/java/org/glom/web/OnlineGlom.gwt.xml: Inherit only the resources from the standard gwt css theme. Standard.css is now included in OnlineGlom.html so that the online glom css rules have precedence over the gwt theme. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Pass the whole LayoutGroup to the DetailsView instead of just the titles. * src/main/java/org/glom/web/client/ui/DetailsView.java: * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Create the details layout with a helper class (GroupPanel). I might extract this class when I make the full flowtable. * src/main/java/org/glom/web/shared/layout/LayoutItem.java: Add empty string as default so I don't have to worry about NPEs when processing the layout objects. * src/main/webapp/OnlineGlom.html: Add the gwt standard css file (see note beside OnlineGlom.gwt.xml above). * src/main/webapp/style.css: Add default font-size to body to override the font-size set by the standard theme. Don't use h2 tags for group-title. Create new details-cell class. 2011-07-08 Murray Cumming ConfiguredDocument: Set the port number too. * src/main/java/org/glom/web/server/ConfiguredDocument.java (ConfiguredDocument.ConfiguredDocument): Get the port number from the Glom document. Presumably this worked sometimes so far because there is a default port number. 2011-07-08 Murray Cumming ConfiguredDocument: Warn that sqlite and self-hosting are not supported. * src/main/java/org/glom/web/server/ConfiguredDocument.java (ConfiguredDocument.ConfiguredDocument): Check that the hosting mode is correct, though we should throw an exception too. 2011-07-08 Murray Cumming Fix a addDocuemnt typo. * src/main/java/org/glom/web/shared/Documents.java (Documents.addDocuemnt): Rename to addDocument(). * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java (OnlineGlomServiceImpl.getDocuments): Adapt. 2011-07-08 Murray Cumming Slightly improved log output when connection fails. * src/main/java/org/glom/web/server/ConfiguredDocument.java (ConfiguredDocument.setUsernameAndPassword): We don't know for sure if it' the username/password that's wrong, so rephrase the message. Also ouput the exception message, though it's generic in this case. 2011-07-08 Ben Konrath Cleanup comments. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Also added braces to a one line if statement because the Eclipse formatter was getting confused. 2011-07-07 Ben Konrath Update project config files for Eclipse 3.7 and use GWT 2.3.0. These should really be two separate tasks but I counldn't get things to work with GWT 2.2.0 and Eclipse 3.7. * .classpath: * .project: * .settings/org.eclipse.jdt.core.prefs: * .settings/org.eclipse.jdt.ui.prefs: * .settings/org.eclipse.ltk.core.refactoring.prefs: * .settings/org.eclipse.m2e.core.prefs: Add new config files. Update current files. Remove references to the webtools plugins as we're not using any of the webtools features. * .gitignore: Add logs directory which is created when running with 'mvn gwt:run'. * pom.xml: Update to GWT 2.3.0. Eclipse configuration was automatically added. * src/main/java/org/glom/web/OnlineGlom.gwt.xml: Moved from src/main/resources/org/glom/web/OnlineGlom.gwt.xml as per this known limitation: http://mojo.codehaus.org/gwt-maven-plugin/eclipse/google_plugin.html#Limitations 2011-07-07 Murray Cumming onlineglom.properties: Add explanatory comments. * src/main/resources/onlineglom.properties: Also change the default user from ben to someuser, to avoid the risk of people thinking we just stupidly hard-coded a locale path, when they see that on stderr or in a log. 2011-06-28 Ben Konrath Use filename in Log for incorrect passwords. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Add getFileName(String) method to get the filename from the URI. 2011-06-28 Ben Konrath Add the table name to the URL token for the ListPlace. This makes things consistent between the DetailsPlace and the ListPlace. It also allows the the ListPlace to be bookmarked. * 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: Remove getDefaultListLayout(). The default layout is now returned by the getListLayout() method when the table name is an empty string. * src/main/java/org/glom/web/client/activity/ListActivity.java: Add table name field. Change to a new ListPlace when the table has been changed. Use getListLayout() for getting the default list layout. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: Add table name field. Set the correct table name in the list box when loading from bookmark. This corrects a problem for the DetailsPlace too. * src/main/java/org/glom/web/client/place/DetailsPlace.java: Move table name to super-class (HasSelectableTable). Move document and table URL keys to super-class in HasSelectableTable. * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java: Add table name field. Add Tokenizer class with URL key common to the subclasses (DetailsPlace and ListPlace). * src/main/java/org/glom/web/client/place/ListPlace.java: Add table name. Add code to parse the URL token. * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java: Update ListPlace construction with empty table name string. * src/main/java/org/glom/web/client/ui/TableSelectionView.java: * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java: Change setTableSelectedIndex(int) to setSelectedTableName(String). Update ListPlace construction with table name string. * src/main/java/org/glom/web/shared/layout/LayoutGroup.java: Change defaultTableName field to tableName to reflect how it's now used. Update the getter and setter methods. 2011-06-28 Ben Konrath Enable the table selector in the DetailsView. * 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: Remove getDefaultDetailsLayout(). The default layout is now returned by the getDetailsLayout() method when the table name is an empty string. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Add event handler for table change event. Change to using getDetailsLayout() for the default details layout. * src/main/java/org/glom/web/client/place/DetailsPlace.java: Add table name to URL token. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Use table when navigating to the details place. 2011-06-27 Ben Konrath Use filename based unique document ID in URL and for RPC. The document ID is the glom document name with spaces (' ') replaced with pluses ('+') and without the .glom extension. This change is mostly a string substitution of 'documentTitle' for 'documentID'. The only code change is the addition of a Documents DTO to get the filename to document title mappings as indicated below. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: * src/main/java/org/glom/web/client/activity/DetailsActivity.java: * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java: Use Documents DTO to create the document links in the document selection view. * 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/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: * 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/server/Log.java: * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Change getDocumentTitles() to getDocuments() and return the Documents DTO. * src/main/java/org/glom/web/shared/Documents.java: New DTO for transferring the filename to document title mappings. 2011-06-25 Ben Konrath Make the authentication popup work again. This bug was introduced when I extracted ConfiguredDocument to its own class. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Return the correct success / fail status in setUsernameAndPassword(). 2011-06-25 Ben Konrath Use filename as unique key for configuring database usernames and passwords. This replaces the use of the Glom document title which could change depending on the locale. Thanks to Murray Cumming for pointing out this problem. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: * src/main/resources/onlineglom.properties: 2011-06-24 Ben Konrath Pass primary key value to DetailsView. This enables the DetailsView to load the correct data. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Add primary key value field and set in constructor. Pass primary key value to getDetailsData(). * src/main/java/org/glom/web/client/place/DetailsPlace.java: Add URL variables for document title and primary key value. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Pass primary key value to the DetailsPlace. 2011-06-24 Ben Konrath Add primary key index to LayoutGroup DTO and add ProvidesKey to CellTable. This allows the primary key to be retrieved by the Details button. This functionality has not been implemented yet but it's in the works. * src/main/java/org/glom/web/client/activity/ListActivity.java: Pass the LayoutGroup result to ListView.setCellTable instead of all of its fields individually. * src/main/java/org/glom/web/client/ui/ListView.java: * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Use LayoutGroup as parameter for setCellTable. Add ProvidesKey to CellTable get the primary key for the table. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Set the index of the primary key in the LayoutGroup accounting for hidden primary keys. Rename getJavaNumberFormat() to convertToJavaNumberFormat() for consistency. Cleanup / add some comments. * src/main/java/org/glom/web/shared/layout/LayoutGroup.java: Add a field for primary key index and a field to indicate whether the primary key is hidden or not. 2011-06-23 Ben Konrath Rename getTableData methods to getListData. This is a rename refactor for consistency with other methods. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: * src/main/java/org/glom/web/client/ui/ListViewImpl.java: * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-06-23 Ben Konrath Extract the ConfiguredDocument innerclass into its own class. This makes the servlet code more object oriented. * src/main/java/org/glom/web/server/ConfiguredDocument.java: Extracted from private ConfiguredDocument class in OnlineGlomServiceImpl. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Use the new ConfiguredDocument class. 2011-06-21 Ben Konrath Use the LayoutGroup group for the list layout instead of ColumnInfo and LayoutListTable. This makes things more inline with how libglom works and reduces code duplication. This refactor lays the groundwork for adding the primary key to the LayoutGroup object. * 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: Change method names to getListLayout and getDefaultListLayout for consistency. Use LayoutGroup as the DTO for the list layout instead of ColumnInfo and LayoutListTable. * src/main/java/org/glom/web/client/activity/ListActivity.java: Use the new method names along with the LayoutGroup object for transferring the list layout. * src/main/java/org/glom/web/client/ui/ListView.java: * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Use ArrayList instead of ColumnInfo[] in setCellTable(). * src/main/java/org/glom/web/shared/ColumnInfo.java: Deleted. Replaced with LayoutGroup. * src/main/java/org/glom/web/shared/LayoutListTable.java: Deleted. Replaced with LayoutGroup. * src/main/java/org/glom/web/shared/layout/LayoutGroup.java: Add expectedResultSize and defaultTableName fields which are needed for the list layout. * src/main/java/org/glom/web/shared/layout/LayoutItemField.java: Add type field which is needed for the list layout but will also be useful for the details layout as things progress. * src/main/java/org/glom/web/shared/layout/LayoutItemWithFormatting.java: Make class abstract. Remove the unnecessary getFormattingHorizontalAlignment method. Add setFormatting method. 2011-06-16 Ben Konrath Add scripts for building and installing war. These will help when updating OnlineGlom but they're also good supplemental documentation of the build and deployment proceeding. * utils/build-onlineglom-war.sh: New file. * utils/install-onlineglom-war.sh: New file. 2011-06-16 Ben Konrath Create wrapper class to create consistent log messages. I wrapped methods in the Log class of gwt-log to add the method names from the servlet and create consistent formatting of the document title and table names in the log messages. * src/main/java/org/glom/web/server/Log.java: New file with wrapped methods. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Convert all log methods to use methods from wrapped Log class. 2011-06-16 Ben Konrath Remove superfluous conditional return. Thanks to Murray Cumming for pointing this out! * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-06-15 Ben Konrath Return an ArrayList of LayoutGroups for the Details layout. This corrects a problem with the details layout as it can have more than one top level LayoutGroup. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Change method name from get*DetailsLayoutGroup to get*DetailsLayout. Return an ArrayList in the get*DetailsLayout methods. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Deal with ArrayList of LayoutGroups for the details view layout. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Change method name from get*DetailsLayoutGroup to get*DetailsLayout. Return an ArrayList in the get*DetailsLayout methods. Inline getTableFieldsToShowForSequence() into getFieldsToShowForSQLQuery() to simplify the code a bit. Rename getTableFieldsToShowForSequenceAddGroup() to getFieldsToShowForSQLQueryAddGroup() to try to keep things more consistent. 2011-06-14 Ben Konrath Use cast_dynamic method to determine the libglom LayoutItem type. This is better than finding the LayoutItem type by using the string returned from the get_part_type_name() method. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-06-14 Ben Konrath Add method names to log entries in the servlet. This helps when tracking down deployment problems. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-06-14 Ben Konrath Add data to the DetailsView using a hard-coded primary key value. The layout and functionality of the DetailsView is not complete. This is just a checkpoint so the patch doesn't get too big. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Add getDetailsData() servlet method. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Add RPC to getDetailsData(). Change the way the LayoutGroups and LayoutFields are added to the DetailsView. * src/main/java/org/glom/web/client/ui/DetailsView.java: * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Add setData() method. Change addLayoutGroup() and addLayoutField() to take the string for the title instead of the object. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Add implementation getDetailsData() along with some private helper methods. * src/main/webapp/style.css: Add padding to details-data class. Add a details-label class with the same padding as the details-data class. 2011-06-03 Ben Konrath Use presenter.goTo() to change to the DetailsPlace. This will make things easier when we need to open the DetailsView with data specific to the row that was clicked. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: 2011-06-02 Ben Konrath Add CSS file from mockups. I'm adding this now because it's going to be useful to have when developing the DetailsView. The TableSelectionView and ListView aren't setup properly yet. * src/main/webapp/OnlineGlom.html: * src/main/webapp/style.css: 2011-06-02 Ben Konrath Use String.isEmpty() to check for empty string. * src/main/java/org/glom/web/client/activity/ListActivity.java: 2011-06-02 Ben Konrath Display main layout group titles in the DetailsView. This is the start of the DetailsActivity/DetailsView implementation. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Add getDetailsLayoutGroup() and getDefaultDetailsLayoutGroup() methods. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Get the layout information for the details view from the server and set the main layout group titles. * src/main/java/org/glom/web/client/ui/DetailsView.java: * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: Add addLayoutGroup() and addLayoutField() methods. This are just temporary methods for creating the the details view that will change in the future. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Implement getDetailsLayoutGroup() and getDefaultDetailsLayoutGroup() methods. * src/main/java/org/glom/web/shared/layout/Formatting.java: * src/main/java/org/glom/web/shared/layout/LayoutGroup.java: * src/main/java/org/glom/web/shared/layout/LayoutItem.java: * src/main/java/org/glom/web/shared/layout/LayoutItemField.java: * src/main/java/org/glom/web/shared/layout/LayoutItemWithFormatting.java: Data Transfer Objects that mimic the libglom object structure. These are used for transferring the details layout but could also be used for transferring the list layout. 2011-05-27 Ben Konrath Reset the AuthenticationPopup when clearing the ListView. * src/main/java/org/glom/web/client/activity/ListActivity.java: 2011-05-27 Ben Konrath Fix problem with onlineglom.properties file loading. The old way worked in Eclipse but not on the server. Loading the onlineglom.properties file now works in Eclipse and on the server. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-05-24 Ben Konrath Update gwt-log from 3.1.0 to 3.1.2. Gwt-log 3.1.0 has been marked as depreciated. * pom.xml: 2011-05-24 Ben Konrath Add comment to ListActivity.goTo() method. * src/main/java/org/glom/web/client/activity/ListActivity.java: 2011-05-24 Ben Konrath Remove FIXME in convertGdkColorToHtmlColour() The Gdk::Color value returned by libglom is 16-bits per channel on both 64 and 32-bit platforms. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-05-19 Ben Konrath Improve performance of initial ListView load. I removed a round trip to the server for getting the default table name and then requesting information about that table. This also removes a potential problem with the table change handler not being setup in time to receive the table change event from the ListActivity. * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Add getDefaultLayoutListTable() method. Improve comments. * src/main/java/org/glom/web/client/activity/ListActivity.java: Use getDefaultLayoutListTable() method instead of firing a table change event to get the table to load. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Add implementation of getDefaultLayoutListTable() method. * src/main/java/org/glom/web/shared/LayoutListTable.java: Add field for table name. 2011-05-19 Ben Konrath Override toDebugString() in TableChangeEvent. This is useful to have for debugging. * src/main/java/org/glom/web/client/event/TableChangeEvent.java: 2011-05-19 Ben Konrath Add a "Back to List" link when at the DetailsPlace. * src/main/java/org/glom/web/client/activity/ListActivity.java: Populate the CellTable based on the selected table of the ListBox if it's set otherwise use the default table. This allows the "Back to List" link to work. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: Remove Place from constructors. Add a setPlace() method. Add goToPlace() method. Set class as presenter for TableSelectionView. * src/main/java/org/glom/web/client/mvp/TableSelectionActivityMapper.java: Use the same TableSelectionActivity when switching between the List and Details Places. * src/main/java/org/glom/web/client/place/DetailsPlace.java: Subclass the new HasSelectableTablePlace. This removes some duplicate code. * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java: New class to represent Places that display the TableSelectionView. * src/main/java/org/glom/web/client/place/ListPlace.java: Subclass the new HasSelectableTablePlace. This removes some duplicate code. * src/main/java/org/glom/web/client/ui/TableSelectionView.java: * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java: Add Presenter interface. Add setBackLinkVisible() method. Add setBackLink() method. 2011-05-18 Ben Konrath Enable the "Details" buttons. Right now only an empty details view is displayed. * src/main/java/org/glom/web/client/ClientFactory.java: * src/main/java/org/glom/web/client/ClientFactoryImpl.java: Add DetailsView to ClientFactory. * src/main/java/org/glom/web/client/activity/DetailsActivity.java: A basic activity for the details view. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: Add a new constructor that takes a DetailsPlace. Rename shutdown() to clearView(). * src/main/java/org/glom/web/client/mvp/AppPlaceHistoryMapper.java: Add DetailsPlace.Tokenizer to the list of tokens that are generated by GWT. * src/main/java/org/glom/web/client/mvp/DataActivityMapper.java: Create a new DetailsActivity when a DetailsPlace is requested. Remove unnecessary super() in constructor. * src/main/java/org/glom/web/client/mvp/TableSelectionActivityMapper.java: Create a new TableSelectionActivity when a DetailsPlace is requested. We really shouldn't create a new TableSelectionActivity for both the ListPlace and the DetailsPlace so this should be considered a temporary solution. * src/main/java/org/glom/web/client/place/DetailsPlace.java: New file. Represents a URL for the details view. * src/main/java/org/glom/web/client/ui/DetailsView.java: * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java: A basic details view interface and implementation. * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Enable the "Details" buttons. 2011-05-12 Ben Konrath Use a LayoutPanel with multiple display areas for main layout. This is mostly a refactor in that there are no changes from the user point of view. These changes are required so that we can swap out the list view with the details view when the user clicks the "Details" button. * src/main/java/org/glom/web/client/ClientFactory.java: * src/main/java/org/glom/web/client/ClientFactoryImpl.java: Remove OnlineGlomView. Add TableSelectionView, ListView and AuthenticationPopup. * src/main/java/org/glom/web/client/OnlineGlom.java: Use LayoutPanel for main layout. Add display regions for main activities. Add activity manager for for main activities. * src/main/java/org/glom/web/client/activity/ListActivity.java: New file from parts of the deleted OnlineGlomActivity. * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java: New file from parts of the deleted OnlineGlomActivity. * src/main/java/org/glom/web/client/event/TableChangeEvent.java: * src/main/java/org/glom/web/client/event/TableChangeEventHandler.java: New files for app wide table change event. * src/main/java/org/glom/web/client/mvp/DataActivityMapper.java: * src/main/java/org/glom/web/client/mvp/DocumentSelectionActivityMapper.java: * src/main/java/org/glom/web/client/mvp/TableSelectionActivityMapper.java: Activity mappers for the main activities replace the deleted app-wide AppActivityMapper. * src/main/java/org/glom/web/client/ui/AuthenticationPopup.java: Fix a spelling error in he comment. * src/main/java/org/glom/web/client/ui/ListView.java: * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Renamed from LayoutListView and modified for MVP. This still not a proper dumb view as prescribed by the MVP pattern but it works for now. * src/main/java/org/glom/web/client/ui/TableSelectionView.java: * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java: New widget stripped out of the deleted OnlineGlomView. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Remove hack that is fixed by this patch. 2011-05-06 Ben Konrath Rename OnlineGlomPlace to ListPlace. The only change besides the rename is that url will now display #list instead of #Document. * src/main/java/org/glom/web/client/activity/OnlineGlomActivity.java: * src/main/java/org/glom/web/client/mvp/AppActivityMapper.java: * src/main/java/org/glom/web/client/mvp/AppPlaceHistoryMapper.java: * src/main/java/org/glom/web/client/place/ListPlace.java: * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java: 2011-05-06 Ben Konrath Use Presenter for app navigation. This is the proper way to deal with Place (URL) changes with the MVP framework. * src/main/java/org/glom/web/client/ClientFactory.java: * src/main/java/org/glom/web/client/ClientFactoryImpl.java: Remove PlaceHistoryMapper and PlaceHistoryHandler. * src/main/java/org/glom/web/client/OnlineGlom.java: Re-add PlaceHistoryMapper and PlaceHistoryHandler. * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java: Don't use getHistoryMapper().getToken(place) to create the hyperlinks. * src/main/java/org/glom/web/client/ui/DocumentSelectionView.java: * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java: Add Presenter interface and setPresenter methods. Rename addHyperLink to addDocumentLink taking only the document title as a parameter. 2011-04-14 Ben Konrath Prompt for db username/password if they haven't been set. This is implemented with a popup widget that is contained within the OnlineGlomView and managed by the OnlineGlomActivity. * src/main/java/org/glom/web/client/OnlineGlomService.java: Two new methods for checking and setting the database username and password. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Two new methods for checking and setting the database username and password. * src/main/java/org/glom/web/client/activity/OnlineGlomActivity.java: Display authentication popup if the JDBC connection to the database has not been authenticated. * src/main/java/org/glom/web/client/ui/AuthenticationPopup.java: New file. * src/main/java/org/glom/web/client/ui/OnlineGlomView.java: Add methods for dealing with the authentication popup. * src/main/java/org/glom/web/client/ui/OnlineGlomViewImpl.java: Implement the methods for dealing with the authentication popup. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Don't try to executed queries if the database connection hasn't been authenticated. Implement methods for checking and setting the database username and password. 2011-04-12 Ben Konrath Make log messages a little clearer. Add a dash betweeen the document title and the table name. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-04-12 Ben Konrath Protect against NPEs when cleaning up database resources. While this isn't strictly necessary because the exception is caught, not protecting against the NPEs makes it harder to find the real error in the log file. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-04-12 Ben Konrath Move configuration of the servlet to the constructor. The servlet will be initialized even if the database authentication information is not set or correct. I still need to add the UI for prompting the user for the authentication information when it's required. * src/main/java/org/glom/web/client/OnlineGlomService.java: Add javadocs for getDocumentTitles() method. * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java: Set error message when RPC fails. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Get the glom files directory from the configuration file. Try to set the database authentication information for the specific document if it's set and works otherwise try to use the global authentication information set for the directory. * src/main/resources/onlineglom.properties: Moved from src/main/webapp/WEB-INF/OnlineGlom.properties. Updated with new keys. Added detailed comments for the new keys. 2011-04-11 Ben Konrath Remove unnecessary @Override in DocumentSelectionViewImpl. * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java: 2011-04-11 Ben Konrath Remove center alignment in DocumentSelectionView. The title element is still centred but the document titles and bottom sentence are both left-aligned. * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.ui.xml: 2011-04-11 Ben Konrath Change 'Demo' naming convention to 'Document'. This is just a rename refactor with no functional changes to the code. * src/main/java/org/glom/web/client/ClientFactory.java: * src/main/java/org/glom/web/client/ClientFactoryImpl.java: * src/main/java/org/glom/web/client/OnlineGlom.java: * src/main/java/org/glom/web/client/OnlineGlomService.java: * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java: * src/main/java/org/glom/web/client/mvp/AppActivityMapper.java: * src/main/java/org/glom/web/client/mvp/AppPlaceHistoryMapper.java: * src/main/java/org/glom/web/client/place/DocumentSelectionPlace.java: * 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/DocumentSelectionViewImpl.ui.xml: * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-04-08 Ben Konrath Remove FIXME from safeLongToInt() method. Libglom uses longs on 32-bit and 64-bit platforms so it's ok to use this method. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-04-08 Ben Konrath Display an error if no glom documents are found in the specified directory. * src/main/java/org/glom/web/client/activity/DemoSelectionActivity.java: * src/main/java/org/glom/web/client/ui/DemoSelectionView.java: * src/main/java/org/glom/web/client/ui/DemoSelectionViewImpl.java: * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-04-08 Ben Konrath Add copyright header to one more file ... oops. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: 2011-04-08 Ben Konrath Add copyright header to files without it. * src/main/java/org/glom/web/client/activity/DemoSelectionActivity.java: * src/main/java/org/glom/web/client/place/DemoSelectionPlace.java: * src/main/java/org/glom/web/client/ui/DemoSelectionView.java: * src/main/java/org/glom/web/client/ui/DemoSelectionViewImpl.java: * src/main/java/org/glom/web/shared/ColumnInfo.java: * src/main/java/org/glom/web/shared/GlomField.java: 2011-04-08 Ben Konrath Add support for accessing multiple glom documents in the servlet. This completes the demo selection functionality. * src/main/java/org/glom/web/client/OnlineGlomService.java: Add document title to methods. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Add document title to methods. * src/main/java/org/glom/web/client/activity/DemoSelectionActivity.java: Set browser window title when the activity starts. Correct name of document title variable. * src/main/java/org/glom/web/client/activity/OnlineGlomActivity.java: Set browser window title when the activity starts. Set the table selector change handler after table selector has been set. Clear the OnlineGlomView when the activity has been stopped. * src/main/java/org/glom/web/client/place/OnlineGlomPlace.java: Use the document title as the place token. Use "#Document:" instead of "#OnlineGlomPlace:" in the URL. * src/main/java/org/glom/web/client/ui/DemoSelectionViewImpl.ui.xml: Change heading to "Online Glom" * src/main/java/org/glom/web/client/ui/LayoutListView.java: Use document title in RPC methods. * src/main/java/org/glom/web/client/ui/OnlineGlomView.java: Remove setDocumentTitle() method. Add clear() method. * src/main/java/org/glom/web/client/ui/OnlineGlomViewImpl.java: Remove setDocumentTitle() method. Implement clear() method which removes the change handler on the ListBox, clears the ListBox and clears the DataPanel. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Implement methods with document title. Keep track for the configured glom documents and their corresponding JDBC configurations in a hash table. This information is retrieved using the document title as the key in the hash table. * src/main/java/org/glom/web/shared/GlomDocument.java: Remove document title field as it's no longer needed. 2011-04-08 Ben Konrath Update the Eclipse JDT configuration. * .settings/org.eclipse.jdt.ui.prefs: Automatically add comments to new methods. Automatically add the copyright header to new files. 2011-04-05 Ben Konrath Add new page for demo selection. This patch adds all the components required to view and start an OnlineGlom demo by clicking on the desired hyperlink. The user is able to return to the demo selection page with the browser's back button. I still need to modify the servlet to work with multiple documents so all demo links will load the file defined in the OnlineGlom.properties. * .gitignore: Add .gwt which holds the error log for the GWT UiBuidler. This is only useful during development so we don't need to save it. * src/main/java/org/glom/web/client/ClientFactory.java: Add method to get a reference to the DemoSelectionView. * src/main/java/org/glom/web/client/ClientFactoryImpl.java: Implement method to get a reference to the DemoSelectionView. * src/main/java/org/glom/web/client/OnlineGlom.java: Change the default view to DemoSelectionView. * src/main/java/org/glom/web/client/OnlineGlomService.java: Add method to get glom document titles for glom files in a hard-coded directory. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Add method to get glom document titles for glom files in a hard-coded directory. * src/main/java/org/glom/web/client/activity/DemoSelectionActivity.java: Presenter for DemoSelectionView. * src/main/java/org/glom/web/client/mvp/AppActivityMapper.java: Update for DemoSelectionView. * src/main/java/org/glom/web/client/mvp/AppPlaceHistoryMapper.java: Update for DemoSelectionView. * src/main/java/org/glom/web/client/place/DemoSelectionPlace.java: Basic 'Place' implementation for the DemoSelectionView. * src/main/java/org/glom/web/client/ui/DemoSelectionView.java: The interface for the DemoSelectionView. * src/main/java/org/glom/web/client/ui/DemoSelectionViewImpl.java: The implementation of the DemoSelectionView. * src/main/java/org/glom/web/client/ui/DemoSelectionViewImpl.ui.xml: The GWT UiBuilder xml file used in DemoSelectionViewImpl. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Add implementation of method to get glom document titles for glom files in a hard-coded directory. * src/main/webapp/OnlineGlom.html: Remove link to CSS file as it's on longer being used. * src/main/webapp/glom.png: Glom logo. 2011-04-05 Ben Konrath Move RPC code from OnlineGlomViewImpl to OnlineGlomActivity. This is the forth and final commit of a refactor that will allow OnlineGlom to be used with multiple documents. * src/main/java/org/glom/web/client/activity/OnlineGlomActivity.java: Move RPC code from OnlineGlomViewImpl to this class. * src/main/java/org/glom/web/client/ui/OnlineGlomView.java: Add methods to inferface. * src/main/java/org/glom/web/client/ui/OnlineGlomViewImpl.java: Move RPC code to the presenter class (the P in MVP). 2011-04-04 Ben Konrath Start moving the existing OnlineGlom code to MVP. This work is based on the GWT MVP framework that is documented here: https://code.google.com/webtoolkit/doc/2.2/DevGuideMvpActivitiesAndPlaces.html This is the third commit of a refactor that will allow OnlineGlom to be used with multiple documents. * src/main/java/org/glom/web/client/ClientFactory.java: New file. Interface for client factory which is used to get instances of various classes throughout the app. * src/main/java/org/glom/web/client/ClientFactoryImpl.java: New file. Implementation of client factory. * src/main/java/org/glom/web/client/OnlineGlom.java: Add code to initialize the MVP framework. * src/main/java/org/glom/web/client/activity/OnlineGlomActivity.java: New file. Activity manager for the main container widget. This is the Presenter in MVP. * src/main/java/org/glom/web/client/mvp/AppActivityMapper.java: New file. Maps place (URL) to its corresponding activity. * src/main/java/org/glom/web/client/mvp/AppPlaceHistoryMapper.java: New file. This is just a place holder for a generated file. * src/main/java/org/glom/web/client/place/OnlineGlomPlace.java: New file. Represents the URL for the main Online Glom app. * src/main/java/org/glom/web/client/ui/LayoutListView.java: Update for changes in LayoutListViewImpl. * src/main/java/org/glom/web/client/ui/OnlineGlomView.java: Create interface for View. Move code to OnlineGlomViewImpl class. * src/main/java/org/glom/web/client/ui/OnlineGlomViewImpl.java: New file. Implementation of OnlineGlomView. * src/main/resources/org/glom/web/OnlineGlom.gwt.xml: Add Activity and Place resources. Use ClientFactoryImpl by default. 2011-04-04 Ben Konrath Move View classes to their own package. This is the second commit of a refactor that will allow OnlineGlom to be used with multiple documents. * src/main/java/org/glom/web/client/OnlineGlom.java: * src/main/java/org/glom/web/client/ui/LayoutListView.java: * src/main/java/org/glom/web/client/ui/OnlineGlomView.java: 2011-04-02 Ben Konrath Move UI code from the main module to its own class. This is the first commit of a refactor that will allow OnlineGlom to be used with multiple documents. * src/main/java/org/glom/web/client/LayoutListView.java: Update references to OnlineGlom to OnlineGlomView. * src/main/java/org/glom/web/client/OnlineGlom.java: Move code to OnlineGlomView and instantiate it here. * src/main/java/org/glom/web/client/OnlineGlomView.java: New class that represents the main OnlineGlomView with one document. 2011-04-01 Ben Konrath Fix formatting of gwt.xml and add DTD. * src/main/resources/org/glom/web/OnlineGlom.gwt.xml: 2011-03-30 Ben Konrath Propperly convert gdkColor string to html colour string. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-03-28 Ben Konrath Change implementation of OnlineGlomServiceImpl.getColumnInfoHorizontalAlignment(). This implementation matches OnlineGlomServiceImpl.getColumnInfoGlomFieldType(), should perform better, is more readable and is not tied to Swig. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-03-28 Ben Konrath Use read-only checkboxes for boolean field types. * src/main/java/org/glom/web/client/LayoutListView.java: Create columns in the CellTable based on the field type. It currently only distinguishes between boolean and text columns but I'll need to add support for more types. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Set the column type in the ColumnInfo object. Add method to convert between the glom field type enum in ColumnInfo and the glom field type in libglom. * src/main/java/org/glom/web/shared/ColumnInfo.java: Add support for field type. * src/main/java/org/glom/web/shared/GlomField.java: Add support for getting and setting booleans. 2011-03-25 Ben Konrath Don't get the Date twice from the ResultSet. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-03-25 Ben Konrath Cleanup code in the servlet. * TODO: Remove item about row count. Add item about testing row count query with large number of rows. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Fix spelling mistakes, change method parameter to be consistent with other methods. 2011-03-25 Ben Konrath Add server side logging with the gwt-log library. * .gitignore: Ignore the log file we're now producing. * TODO: Add a couple TODO item for logging. * pom.xml: Add gwt-log and log4j as a dependency. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Add logging of errors, warnings and some important info. * src/main/resources/log4j.properties: New file to configure log4j. 2011-03-24 Ben Konrath Add a disable button for the Details view. * src/main/java/org/glom/web/client/LayoutListView.java: 2011-03-22 Ben Konrath Use a count query to get the number of rows for the list view pager. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-03-22 Ben Konrath Add more TODO information about CellTable pager positioning. * TODO: 2011-03-19 Ben Konrath Add TODO item about CellTable pager positioning. * TODO: 2011-03-18 Ben Konrath Remove unneeded GlomFieldColumn class. This is just a small code cleanup. * src/main/java/org/glom/web/client/LayoutListView.java: 2011-03-18 Ben Konrath Use cursor mode in the query that gets data for the list view. I still need to fix the potential memory problem when getting the row count for the list view. * TODO: Add note about testing memory usage with large data sets. Add item about fixing row counting with large data sets. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Put the PostgreSQL JDBC driver into cursor mode when getting data for the list view. 2011-03-15 Ben Konrath Remove the GWT Container from the Eclipse build classpath. The GWT dependencies are set by Maven so this isn't needed. * .classpath: 2011-03-15 Murray Cumming Added some earlier mockups to git, but not to the tarball dist. * mockups/: Added some mockups from 2010-02 by Daniel Borgmann for Openismus. These hopefully show how we might structure the HTML so that it can be styled easily with CSS. However, we probably need to adapt them for the CSS structure that GWT dictates for common widgets. 2011-03-14 Ben Konrath Locate OnlineGlom.properties using the ServletContext. This is required to be able to locate the file in the deployed servlet. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Configure the database and glom document in in a helper method so that the ServletContext can be used to locate OnlineGlom.properties. * src/main/webapp/WEB-INF/OnlineGlom.properties: Moved from src/main/webapp. This is the proper location for .properites files. 2011-03-12 Ben Konrath Add note to README about why we're compiling down to obfuscated JavaScript. * README: 2011-03-11 Ben Konrath Use properties file to configure servlet. This allows people to change the glom file path, db username and db password without recompiling the code. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: * src/main/webapp/OnlineGlom.properties: 2011-03-11 Ben Konrath Use table fields in layout list view if the layout list is not defined. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Manually create a LayoutFieldVector for the query builder using the table fields when a layout list is not defined in the glom file. 2011-03-11 Ben Konrath Only show FIXME string for images when there's an image. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Also included in this change are some small code cleanups. 2011-03-11 Ben Konrath Set text for fields with TYPE_IMAGE and TYPE_INVALID to avoid NPEs. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: 2011-03-11 Ben Konrath Correctly set the index of the default table. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Correctly set the index of the default table. Add commented out example file paths. 2011-03-10 Ben Konrath Add comment to pom.xml about the previous change. * pom.xml: Add comment about the deployment issue so that it's obvious why java-libglom is set to the provided scope. 2011-03-10 Ben Konrath Change java-libglom dependency from compile to provided in pom.xml. Since java-libglom uses jni it can only be loaded once and therefore must be placed in $CATALINA_HOME/lib and not included in each war. This directory is defined as /usr/share/tomcat6/lib/ on Ubuntu 10.04. More information about this issue can be found in the Tomcat 6 release notes in the "JNI Based Applications" section: http://tomcat.apache.org/tomcat-6.0-doc/RELEASE-NOTES.txt * README: Remove note about this issue. Deployment info should really be on the wiki anyway so I'll add it right now. * pom.xml: Change java-libglom dependency from compile to provided so that it's copied in to the packaged war. 2011-03-09 Ben Konrath Change to using a neutral locale for currency, date and time formatting. This solves the problem of currency values being represented without a space between the currency code and the number (e.g. "EUR5.89" is now represented as "EUR 5.89"). More work is required when we implement a locale preference setting. * TODO: Add note about currency formatting issues with different locales. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Change to using the neutral ROOT locale. 2011-03-09 Ben Konrath Add support for currency codes that are not ISO 4217 codes. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Use the currency code defined in the glom file when it's not 3 characters long or when Java doesn't recognize the string as an ISO 4217 code. 2011-03-08 Ben Konrath Remove test classes, launch configurations and configuration. The test stuff was getting in the way when creating the war. To make the war file you can now do 'mvn clean package'. The packaged war file will be in the target directory. * .classpath: Remove unused classpathentry for tests and i18n. * pom.xml: Remove junit.jar dependency. Properly use gwt.version property. Don't run test or i18n goals when packaging the war. * src/main/webapp/WEB-INF/web.xml: Add xml name space. Correct formatting. Removed files: * OnlineGlomTest-dev.launch: * OnlineGlomTest-prod.launch: * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java: * src/test/resources/org/glom/web/OnlineGlomJUnit.gwt.xml: 2011-03-07 Ben Konrath Update gwt-maven plugin to 2.2.0 and fix other configuation problems. These fixes allow me to use 'mvn deploy' to create the war file. * .classpath: This generated config has been updated by Eclipse. This change was probably triggered by me updating from Eclipse 3.6.1 to 3.6.2. * .gitignore: Add entry to ignore the directory src/main/webapp/WEB-INF/deploy. This directory is generated by Eclipse. * .project: The generated config has been updated by Eclipse. This change was probably triggered by me updating from Eclipse 3.6.1 to 3.6.2. * .settings/com.google.appengine.eclipse.core.prefs: Add empty config so that Eclipse doesn't complain * pom.xml: Update to gwt-maven-plugin 2.2.0. * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java: Move from 'tests' directory to 'client' directory. This is the new gwt-maven-plugin convension. * src/test/resources/org/glom/web/OnlineGlomJUnit.gwt.xml: Correctly refer to org.glom.web.OnlineGlom gwt module and OnlineGlomServiceImpl. 2011-03-07 Ben Konrath Add support for horizontal alignment in the LayoutList columns. * TODO: Remove item about horizontal alignment. Add item about improvements to ColumnInfo. * src/main/java/org/glom/web/client/LayoutListView.java: Set horizontal alignment on the columns. Use ColumnInfo RPC object get the column title and horizontal alignment. * src/main/java/org/glom/web/client/OnlineGlom.java: Update LayoutListView creation with ColumnInfo RPC object. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Create a ColumnInfo object for every LayoutList columnn. Convert the FieldFormatting.HorizontalAlignment to the correct ColumnnInfo.HorizontatlAlignment with the new getColumnInfoHorizontalAlignment helper method. * src/main/java/org/glom/web/shared/ColumnInfo.java: New RPC object to encapsulate column information like alignment and title. This could be used to set the colour instead of on a per cell field basis. * src/main/java/org/glom/web/shared/LayoutListTable.java: Replace column title storage and retrieval with ColumnInfo. 2011-03-04 Ben Konrath Add support for column sorting. * src/main/java/org/glom/web/client/LayoutListView.java: Change AsynDataProvider to be an anonymous inner class. Use new getSortedTableData RPC method when column sort is requested. Set all columns sortable and add an AsyncHandler to activate sorting in the AsyncDataProvider. * src/main/java/org/glom/web/client/OnlineGlomService.java: Add new method getSortedTableData(). Cleanup other method signatures. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Add new method getSortedTableData(). Cleanup other method signatures. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Implement getSortedTableData() and getTableData() methods by using a private helper method with the appropriate parameters filled in. Use user supplied sort clause when supplied, otherwise fall back to sorting by the primary key. Move destroy() method to be underneath constructor for readability. Cleanup comments. 2011-03-03 Ben Konrath Add support for colour text and colour backgrounds to the layout list cells. Only the cell backgrounds are coloured which leaves a gap between the cells that isn't coloured. I need to figure out a way to set 'style=background-colour:' on the whole column rather than just the cell. * TODO: Add a note about colouring the background of the whole column. * src/main/java/org/glom/web/client/LayoutListView.java: Add a custom column type (GlomFieldColumn) and a custom cell type (GlomFieldCell) to render the coloured text and backgrounds. Use GlomField[] for the row type. * src/main/java/org/glom/web/client/OnlineGlomService.java: Use GlomField[] for the row type. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Use GlomField[] for the row type. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Use GlomField[] for the row type. Set the text, text colour and background colour in the GlomField objects as specified in the glom document. Add method to convert from Gdk::Color to HTML colour string. Cleanup comments. * src/main/java/org/glom/web/shared/GlomField.java: New file to encapulate the glom field text, foreground colour and background colour. 2011-03-02 Ben Konrath Don't display hidden tables in the combo box. * src/main/java/org/glom/web/client/OnlineGlom.java: Update code to use ArrayLists. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Add code to ignore hidden tables using ArrayLists for the table names and titles. * src/main/java/org/glom/web/shared/GlomDocument.java: Change tableTitles and tableNames to use ArrayLists instead of String[]. Update getter and setter methods. 2011-03-01 Ben Konrath Add support for Date and Time number types. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Implement formatting for Date and Time values. Change the default glom file to small business example. 2011-03-01 Ben Konrath Add support for formatting glom types as specified in the glom file. Formatting isn't finished yet - I still need to add support for Date and Time values. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Add formatting support for TYPE_TEXT, TYPE_BOOLEAN and TYPE_NUMERIC. Remove checks for null values in JDBC cleanup code and catch all exceptions instead of just SQLExceptions. * src/main/java/org/glom/web/shared/LayoutListTable.java: Fix incorrect method name. 2011-03-01 Ben Konrath Use GWT 2.2.0 instead of 2.1.1. * pom.xml: Change GWT version numbers. 2011-03-01 Ben Konrath A few small code cleanups. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Remove duplicate for loop. * src/main/java/org/glom/web/shared/GlomDocument.java: Remove unnecessary object creation in constructor. * src/main/java/org/glom/web/shared/LayoutListTable.java: Remove unnecessary object creation in constructor. 2011-02-28 Ben Konrath Add file for TODO list. * TODO: New file. 2011-02-18 Ben Konrath Enable the CellTable Pager when more than 20 rows need to be viewed. The Pager will automatically become active when the results are larger than the CellTable size which is currently set to 20 lines. * src/main/java/org/glom/web/client/LayoutListView.java: Correct class name on debug statment in RPC call in LayoutListDataProvider, add numRows parameter to LayoutListView constructor, propperly set rowCount in CellTable. * src/main/java/org/glom/web/client/OnlineGlom.java: Correct class name on debug statment in RPC call, use LayoutListTable object in RPC calls, pass rowCount to LayoutListView. * src/main/java/org/glom/web/client/OnlineGlomService.java: Change getLayoutListHeaders to getLayoutListTable and return LayoutListTable object. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Update interface for changes in OnlineGlomService. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Change getLayoutListHeaders() to getLayoutListTable() and return LayoutListTable. Using this object allows me to pass other information about the LayoutList like the expected number of rows in the result set. The Connection object from the connection pool is now propperly closed. Only the requested number of lines are returned to the client in getTableData(). * src/main/java/org/glom/web/shared/LayoutListTable.java: Move from GlomTable and add columnTitles and numRows. 2011-02-18 Ben Konrath Use String arrays instead of GlomTable objects in GlomDocument GWT-RPC object. This is a small performance boost. I'll use GlomTable to get the required layoutlist information. * src/main/java/org/glom/web/client/OnlineGlom.java: * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: * src/main/java/org/glom/web/shared/GlomDocument.java: 2011-02-18 Ben Konrath Add option to turn off formatting in JDT formatter preferences. * .settings/org.eclipse.jdt.core.prefs: 2011-02-18 Ben Konrath Rename LayoutList to LayoutListView. I'm working towards setting things up to easily use MVP when the time comes. * src/main/java/org/glom/web/client/LayoutListView.java: Rename from LayoutList.java. * src/main/java/org/glom/web/client/OnlineGlom.java: Update references. 2011-02-17 Ben Konrath Move LayoutListDataProvider class into LayoutList.java. * src/main/java/org/glom/web/client/LayoutList.java: 2011-02-17 Ben Konrath Rename RPC service classes from LibGlomService* to OnlineGlomService*. * src/main/java/org/glom/web/client/LayoutListDataProvider.java: Update references. * src/main/java/org/glom/web/client/OnlineGlom.java: Update references. * src/main/java/org/glom/web/client/OnlineGlomService.java: Rename from LibGlomServer.java. * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java: Rename from LibGlomServiceAsync.java. * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: Rename from LibGlomServiceImpl.java. * src/main/webapp/WEB-INF/web.xml: Update configuration. 2011-02-17 Ben Konrath Update JDT settings. * .settings/org.eclipse.jdt.core.prefs: 2011-02-17 Ben Konrath Move GWT-RPC objects to shared package (where they should be). * src/main/java/org/glom/web/client/LibGlomService.java: Update imports. * src/main/java/org/glom/web/client/LibGlomServiceAsync.java: Update imports. * src/main/java/org/glom/web/client/OnlineGlom.java: Update imports. * src/main/java/org/glom/web/server/LibGlomServiceImpl.java: Update imports. * src/main/java/org/glom/web/shared/GlomDocument.java: Move to org.glom.web.shared package. * src/main/java/org/glom/web/shared/GlomTable.java: Move to org.glom.web.shared package. * src/main/resources/org/glom/web/OnlineGlom.gwt.xml: Included shared directory in compilation to javascript. 2011-02-16 Ben Konrath Add sort clause to the sql query that grabs table information. * src/main/java/org/glom/web/server/LibGlomServiceImpl.java: Add sort clause if one of the columns is a primary key. 2011-02-16 Ben Konrath Disable generateAsync feature of gwt-maven. The generated interface does not correctly match the methods in LibGlomService and the generated singleton Util inner-class doesn't respect the servlet mappings. * pom.xml: Turn off generateAsync feature. * src/main/java/org/glom/web/client/LibGlomServiceAsync.java: Re-add file with singleton Util inner-class. 2011-02-14 Ben Konrath Add LGPL v3 licence notices. Followed directions listed here: http://www.gnu.org/licenses/gpl-howto.html * COPYING: This file is a copy of the GPL v3. * COPYING.LESSER: This file is a copy of the LGPL v3. * src/main/java/org/glom/web/client/GlomDocument.java: Add licence notice. * src/main/java/org/glom/web/client/GlomTable.java: Add licence notice. * src/main/java/org/glom/web/client/LayoutList.java: Add licence notice. * src/main/java/org/glom/web/client/LayoutListDataProvider.java: Add licence notice. * src/main/java/org/glom/web/client/LibGlomService.java: Add licence notice. * src/main/java/org/glom/web/client/OnlineGlom.java: Add licence notice. * src/main/java/org/glom/web/server/LibGlomServiceImpl.java: Add licence notice. 2011-02-14 Ben Konrath Use ArrayList instead of Array in GWT-RPC calls. Apparently this gives a slight performance boost to the compiled java script. * src/main/java/org/glom/web/client/LayoutListDataProvider.java: Use ArrayList instead of Array. * src/main/java/org/glom/web/client/LibGlomService.java: Use ArrayList instead of Array. 2011-02-14 Ben Konrath Access data from a postgres db rather than the example glom file. * .settings/com.google.gwt.eclipse.core.prefs: Change GWT setting to compile down to obfuscated javascript. * pom.xml: Add c3p0 and postgres JDBC libraries. * src/main/java/org/glom/web/server/LibGlomServiceImpl.java: Return data using a postgres db accessed through the c3p0 connection pooling library. 2011-02-14 Ben Konrath Update Java formatter settings. * .settings/org.eclipse.jdt.core.prefs: Change comment length to 120. 2011-02-02 Ben Konrath Update Eclipse and Maven configs to in preparation for the postgres JDBC jar. * .classpath: Change JRE to Java 1.6, remove GWT configuration as we're now using Maven. * .settings/com.google.gwt.eclipse.core.prefs: Don't copy gwt-servlet.jar to the compiled webapp directory that Eclipse uses as we're using Maven now. * .settings/org.eclipse.jdt.core.prefs: Change target platform to Java 1.6. * .settings/org.eclipse.wst.common.project.facet.core.xml: Change Java version to 1.6. * pom.xml: Format file, change target Java version to 1.6. 2011-02-02 Ben Konrath Add information about a deployment related issue. * README: Add Notes section with the problem outlined. 2011-02-02 Ben Konrath Call Glom.libglom_deinit() when the servlet is shutdown. * src/main/java/org/glom/web/server/LibGlomServiceImpl.java: Add Glom.libglom_deinit() to destroy() method. 2011-01-28 Ben Konrath Use generated Util class to get the RPC Async interface. * .settings/com.google.gwt.eclipse.core.prefs: Update generated Eclipse config file. * src/main/java/org/glom/web/client/LayoutListDataProvider.java: Use generated getInstance() method to get a reference to the RPC Async interface. * src/main/java/org/glom/web/client/OnlineGlom.java: Use generated getInstance() method to get a reference to the RPC Async interface, remove the now unused getLibGlomServiceProxy() method. 2011-01-27 Ben Konrath Cleanup ChangeLog entry from previous commit. * ChangeLog: Group logical changes together and add comments. 2011-01-25 Ben Konrath Convert to gwt-maven project. * .gitignore: Update for new project structure. * README: New file with a link to the online documentation. * pom.xml: The generated maven configuration file with some tweaks. Add / update Eclipse settings. These files are a merge of the files that were generated with the gwt-maven plugin and the files we were previously using. * .classpath: * .project: * .settings/.jsdtscope: * .settings/com.google.gdt.eclipse.core.prefs: * .settings/com.google.gwt.eclipse.core.prefs: * .settings/org.eclipse.jdt.core.prefs: * .settings/org.eclipse.wst.common.component: * .settings/org.eclipse.wst.common.project.facet.core.xml: * .settings/org.eclipse.wst.jsdt.ui.superType.container: * .settings/org.maven.ide.eclipse.prefs: * OnlineGlomTest-dev.launch: * OnlineGlomTest-prod.launch: Java source files moved from the 'src' directory to the directory structure required by maven. * src/main/java/org/glom/web/client/GlomDocument.java: * src/main/java/org/glom/web/client/GlomTable.java: * src/main/java/org/glom/web/client/LayoutList.java: * src/main/java/org/glom/web/client/LayoutListDataProvider.java: * src/main/java/org/glom/web/client/LibGlomService.java: * src/main/java/org/glom/web/client/OnlineGlom.java: * src/main/java/org/glom/web/server/LibGlomServiceImpl.java: Non-functional property file used for translations. I included this as reminder that it's something I need to sort out. * src/main/resources/org/glom/web/client/Messages.properties: The OnlineGlom GWT config file moved from the 'src/org/glom/web' directory. * src/main/resources/org/glom/web/OnlineGlom.gwt.xml: The servlet configuration files moved from the 'war' directory. * src/main/webapp/OnlineGlom.css: * src/main/webapp/OnlineGlom.html: * src/main/webapp/WEB-INF/web.xml: Generated test files with most of the code commented out. I included these so that it's easy to add tests when we're ready for them. * src/test/java/org/glom/web/tests/GwtTestOnlineGlom.java: * src/test/resources/org/glom/web/OnlineGlomJUnit.gwt.xml: 2011-01-25 Ben Konrath Remove unused println. * src/org/glom/web/server/LibGlomServiceImpl.java: 2011-01-25 Ben Konrath Add project specific JDT settings. * .settings/org.eclipse.jdt.core.prefs: Generated by Eclipse. * .settings/org.eclipse.jdt.ui.prefs: Generated by Eclipse. 2011-01-25 Ben Konrath Populate celltable with example data. * src/org/glom/web/client/GlomDocument.java: Correct formatting. * src/org/glom/web/client/GlomTable.java: Correct formatting. * src/org/glom/web/client/LayoutList.java: Renamed from ListLayoutTable.java, add LayoutListDataProvider to CellTable, add simpler pager (not working yet). * src/org/glom/web/client/LayoutListDataProvider.java: New file, asynchronously gets the example data. * src/org/glom/web/client/LibGlomService.java: Add getTableData() method. * src/org/glom/web/client/LibGlomServiceAsync.java: Add getTableData() method. * src/org/glom/web/client/OnlineGlom.java: Allow service proxy object and curently selected table to be retrieved by other widgets. * src/org/glom/web/server/LibGlomServiceImpl.java: Correct formatting, implement getTableData() in a hacky way. This method needs to be updated to grab information from the database when database creating is implemented. 2011-01-20 Ben Konrath Set table headers when table dropBox changes. * src/org/glom/web/client/GlomDocument.java: Correct some method names. * src/org/glom/web/client/LibGlomService.java: Add method to get list layout field names. * src/org/glom/web/client/LibGlomServiceAsync.java: Add method to get list layout field names. * src/org/glom/web/client/ListLayoutTable.java: New file - composite widget for list layout table. * src/org/glom/web/client/OnlineGlom.java: Add a change handler for the table drop box and add new updateTable() method to asynchronously get the layout list field names for the currently selected table. * src/org/glom/web/server/LibGlomServiceImpl.java: Add server side implementation of getLayoutListHeaders() method. * war/OnlineGlom.html: Remove GlomWebApp div tag as it is not required. 2011-01-18 Ben Konrath Make a listBox with table titles instead of the flexTable demo. This is the start of something more useful. * .classpath: Exclude a bunch of packages from the JVM that are getting in the way of the Eclipse content assist. * src/org/glom/web/client/GlomDocument.java: * src/org/glom/web/client/GlomTable.java: * src/org/glom/web/client/LibGlomService.java: * src/org/glom/web/client/LibGlomServiceAsync.java: * src/org/glom/web/client/OnlineGlom.java: * src/org/glom/web/server/LibGlomServiceImpl.java: * war/OnlineGlom.html: * war/WEB-INF/web.xml: 211-01-13 Ben Konrath Update to new java-libglom API. * .gitignore: Ignore OnlineGlom.war. * src/org/glom/web/server/TableNamesServiceImpl.java: Update to new java-libglom API. 2010-12-20 Ben Konrath Add some basic style to the table listing. * src/org/glom/web/client/OnlineGlom.java: Add style to the table header, print useful error message on async callback failure. * war/OnlineGlom.css: Add style for table header, remove defaults provided by the Eclipse project wizard. 2010-12-20 Ben Konrath Load example file from installed glom dir. * src/org/glom/web/server/TableNamesServiceImpl.java: Use the Java API provided by java-libglom to find the example file. 2010-12-20 Ben Konrath Update Eclipse settings. * .classpath: * .settings/com.google.gdt.eclipse.core.prefs: * .settings/com.google.gwt.eclipse.core.prefs: 2010-12-17 Ben Konrath Initial commit. * .classpath: New file. * .gitignore: New file. * .project: New file. * .settings/com.google.gdt.eclipse.core.prefs: New file. * .settings/com.google.gwt.eclipse.core.prefs: New file. * src/org/glom/web/OnlineGlom.gwt.xml: New file. * src/org/glom/web/client/GlomTable.java: New file. * src/org/glom/web/client/OnlineGlom.java: New file. * src/org/glom/web/client/TableNameService.java: New file. * src/org/glom/web/client/TableNameServiceAsync.java: New file. * src/org/glom/web/server/TableNamesServiceImpl.java: New file. * war/OnlineGlom.css: New file. * war/OnlineGlom.html: New file. * war/WEB-INF/web.xml: New file. * war/images/glom.png: New file.