Permalink
Browse files

Upgrade GWT version (#91)

* Upgrade GWT version

fix #83

* Update API Rest

Fix #83
  • Loading branch information...
darkman97i authored and monkiki committed Aug 24, 2018
1 parent b214feb commit 583374dc9b429f46c2c75b88353fc856cf858267
Showing 529 changed files with 337 additions and 285 deletions.
No changes.
30 pom.xml
@@ -52,14 +52,14 @@
<properties>
<!-- Using this GWT version -->
<gwt.version>2.4.0</gwt.version>
<gwt.version>2.8.2</gwt.version>
<!-- Using this Spring version -->
<spring.version>3.2.8.RELEASE</spring.version>
<spring.version>3.2.9.RELEASE</spring.version>
<spring.security.version>3.2.3.RELEASE</spring.security.version>
<!-- Apache CXF -->
<cxf.version>2.7.12</cxf.version>
<cxf.version>3.2.5</cxf.version>
<!-- Apache POI -->
<poi.version>3.12</poi.version>
@@ -76,10 +76,10 @@
<!-- OpenCMIS -->
<opencmis.version>0.12.0</opencmis.version>
<!-- Tell the compiler we can use 1.7 -->
<java.compiler>1.7</java.compiler>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
<!-- Tell the compiler we can use 1.8 -->
<java.compiler>1.8</java.compiler>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<!-- Default source encoding ${default.encoding} -->
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
@@ -431,20 +431,19 @@
<scope>provided</scope>
</dependency>
<!-- Only for development -->
<!--
<!--
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-dev</artifactId>
<version>${gwt.version}</version>
<scope>provided</scope>
</dependency>
-->
</dependency> -->
<!-- GWT plugins -->
<dependency>
<groupId>com.google.code.gwt-log</groupId>
<groupId>com.allen-sauer.gwt.log</groupId>
<artifactId>gwt-log</artifactId>
<version>3.1.6</version>
<version>3.3.1</version>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
@@ -529,6 +528,12 @@
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-security</artifactId>
<version>${cxf.version}</version>
<exclusions>
<exclusion>
<groupId>net.sf.ehcache</groupId>
<artifactId>ehcache</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
@@ -839,6 +844,7 @@
<module>com.openkm.frontend.Main</module>
</modules>
<localWorkers>4</localWorkers>
<extraJvmArgs>-Xms256m -Xmx2048m</extraJvmArgs>
</configuration>
</plugin>
@@ -33,61 +33,61 @@
private static Logger log = LoggerFactory.getLogger(MimeTypeConfig.class);
// MIME types => NOTE Keep on sync with default.sql
public static String MIME_UNDEFINED = "application/octet-stream";
public static String MIME_RTF = "application/rtf";
public static String MIME_PDF = "application/pdf";
public static String MIME_ZIP = "application/zip";
public static String MIME_POSTSCRIPT = "application/postscript";
public static String MIME_MS_WORD = "application/msword";
public static String MIME_MS_EXCEL = "application/vnd.ms-excel";
public static String MIME_MS_POWERPOINT = "application/vnd.ms-powerpoint";
public static String MIME_MS_WORD_2007 = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
public static String MIME_MS_EXCEL_2007 = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
public static String MIME_MS_POWERPOINT_2007 = "application/vnd.openxmlformats-officedocument.presentationml.presentation";
public static String MIME_OO_TEXT = "application/vnd.oasis.opendocument.text";
public static String MIME_OO_SPREADSHEET = "application/vnd.oasis.opendocument.spreadsheet";
public static String MIME_OO_PRESENTATION = "application/vnd.oasis.opendocument.presentation";
public static String MIME_SWF = "application/x-shockwave-flash";
public static String MIME_DXF = "image/vnd.dxf";
public static String MIME_DWG = "image/vnd.dwg";
public static String MIME_TIFF = "image/tiff";
public static String MIME_JPEG = "image/jpeg";
public static String MIME_GIF = "image/gif";
public static String MIME_PNG = "image/png";
public static String MIME_BMP = "image/bmp";
public static String MIME_PSD = "image/x-psd";
public static String MIME_ICO = "image/x-ico";
public static String MIME_HTML = "text/html";
public static String MIME_TEXT = "text/plain";
public static String MIME_XML = "text/xml";
public static String MIME_CSV = "text/csv";
public static String MIME_SQL = "text/x-sql";
public static String MIME_JAVA = "text/x-java";
public static String MIME_JAR = "application/x-java-archive";
public static String MIME_SH = "application/x-shellscript";
public static String MIME_BSH = "application/x-bsh";
public static String MIME_PHP = "application/x-php";
public static String MIME_SCALA = "text/x-scala";
public static String MIME_PYTHON = "text/x-python";
public static String MIME_PERL = "application/x-perl";
public static String MIME_JAVASCRIPT = "application/javascript";
public static String MIME_GROOVY = "text/x-groovy";
public static String MIME_DIFF = "text/x-diff";
public static String MIME_PASCAL = "text/x-pascal";
public static String MIME_CSS = "text/css";
public static String MIME_CSHARP = "text/x-csharp";
public static String MIME_CPP = "text/x-c++";
public static String MIME_AS3 = "application/x-font-truetype";
public static String MIME_APPLESCRIPT = "text/applescript";
public static String MIME_EML = "message/rfc822";
public final static String MIME_UNDEFINED = "application/octet-stream";
public final static String MIME_RTF = "application/rtf";
public final static String MIME_PDF = "application/pdf";
public final static String MIME_ZIP = "application/zip";
public final static String MIME_POSTSCRIPT = "application/postscript";
public final static String MIME_MS_WORD = "application/msword";
public final static String MIME_MS_EXCEL = "application/vnd.ms-excel";
public final static String MIME_MS_POWERPOINT = "application/vnd.ms-powerpoint";
public final static String MIME_MS_WORD_2007 = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
public final static String MIME_MS_EXCEL_2007 = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
public final static String MIME_MS_POWERPOINT_2007 = "application/vnd.openxmlformats-officedocument.presentationml.presentation";
public final static String MIME_OO_TEXT = "application/vnd.oasis.opendocument.text";
public final static String MIME_OO_SPREADSHEET = "application/vnd.oasis.opendocument.spreadsheet";
public final static String MIME_OO_PRESENTATION = "application/vnd.oasis.opendocument.presentation";
public final static String MIME_SWF = "application/x-shockwave-flash";
public final static String MIME_DXF = "image/vnd.dxf";
public final static String MIME_DWG = "image/vnd.dwg";
public final static String MIME_TIFF = "image/tiff";
public final static String MIME_JPEG = "image/jpeg";
public final static String MIME_GIF = "image/gif";
public final static String MIME_PNG = "image/png";
public final static String MIME_BMP = "image/bmp";
public final static String MIME_PSD = "image/x-psd";
public final static String MIME_ICO = "image/x-ico";
public final static String MIME_HTML = "text/html";
public final static String MIME_TEXT = "text/plain";
public final static String MIME_XML = "text/xml";
public final static String MIME_CSV = "text/csv";
public final static String MIME_SQL = "text/x-sql";
public final static String MIME_JAVA = "text/x-java";
public final static String MIME_JAR = "application/x-java-archive";
public final static String MIME_SH = "application/x-shellscript";
public final static String MIME_BSH = "application/x-bsh";
public final static String MIME_PHP = "application/x-php";
public final static String MIME_SCALA = "text/x-scala";
public final static String MIME_PYTHON = "text/x-python";
public final static String MIME_PERL = "application/x-perl";
public final static String MIME_JAVASCRIPT = "application/javascript";
public final static String MIME_GROOVY = "text/x-groovy";
public final static String MIME_DIFF = "text/x-diff";
public final static String MIME_PASCAL = "text/x-pascal";
public final static String MIME_CSS = "text/css";
public final static String MIME_CSHARP = "text/x-csharp";
public final static String MIME_CPP = "text/x-c++";
public final static String MIME_AS3 = "application/x-font-truetype";
public final static String MIME_APPLESCRIPT = "text/applescript";
public final static String MIME_EML = "message/rfc822";
//public static String MIME_VB = "";
//public static String MIME_RUBY = "";
//public static String MIME_SASS = "";
//public static String MIME_POWERSHELL = "";
//public static String MIME_JAVAFX = "";
//public static String MIME_ERLANG = "";
//public static String MIME_COLDFUSION = "";
//public final static String MIME_VB = "";
//public final static String MIME_RUBY = "";
//public final static String MIME_SASS = "";
//public final static String MIME_POWERSHELL = "";
//public final static String MIME_JAVAFX = "";
//public final static String MIME_ERLANG = "";
//public final static String MIME_COLDFUSION = "";
// Registered MIME types
@@ -1,6 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE module SYSTEM "http://google-web-toolkit.googlecode.com/svn/releases/2.0/distro-source/core/src/gwt-module.dtd">
<!DOCTYPE module SYSTEM "www.gwtproject.org/doctype/2.8.2/gwt-module.dtd">
<module rename-to="frontend">
<!-- 2.6 configuration for styles -->
<public path='public'/>
<!-- Inherit the core Web Toolkit stuff -->
<inherits name="com.google.gwt.user.User"/>
@@ -24,18 +26,25 @@
<entry-point class="com.openkm.frontend.client.Main"/>
<!-- only build for Firefox -->
<!-- <set-property name="user.agent" value="gecko1_8" /> -->
<!-- <set-property name="user.agent" value="gecko1_8" /> -->
<!-- only build for Chrome -->
<!-- <set-property name="user.agent" value="safari" /> -->
<!-- Compile debug levels gwt-log -->
<extend-property name="log_level" values="DEBUG" />
<set-property name="log_level" value="DEBUG" />
<set-property name="log_FirebugLogger" value="DISABLED" />
<!-- <set-property name="log_FirebugLogger" value="DISABLED" /> -->
<set-configuration-property name="log_pattern" value="%d [%-5p] %m%n" />
<!-- Suppress compilation warnings -->
<set-property name="gwt.suppressNonStaticFinalFieldWarnings" value="true"/>
<!--
Use GWT 2.7.0 to debug in Firefox
<add-linker name="xsiframe"/>
<set-configuration-property name='xsiframe.failIfScriptTag' value='FALSE'/>
<set-configuration-property name="devModeUrlWhitelistRegexp" value="http://(localhost|127\.0\.0\.1|192\.168\.1\.34)(:\d+)?/.*" />
-->
</module>
@@ -21,6 +21,9 @@
package com.openkm.frontend.client.widget.categories;
import java.util.Iterator;
import java.util.List;
import com.google.gwt.core.client.GWT;
import com.google.gwt.event.logical.shared.SelectionEvent;
import com.google.gwt.event.logical.shared.SelectionHandler;
@@ -36,9 +39,6 @@
import com.openkm.frontend.client.service.OKMRepositoryServiceAsync;
import com.openkm.frontend.client.util.Util;
import java.util.Iterator;
import java.util.List;
/**
* Folder tree
*
@@ -50,13 +50,14 @@
private TreeItem actualItem;
private final OKMFolderServiceAsync folderService = (OKMFolderServiceAsync) GWT.create(OKMFolderService.class);
private final OKMRepositoryServiceAsync repositoryService = (OKMRepositoryServiceAsync) GWT.create(OKMRepositoryService.class);
TreeItem rootItem = new TreeItem(Util.imageItemHTML("img/menuitem_childs.gif", "root_schema", "top"));
TreeItem rootItem = new TreeItem();
/**
* Folder Tree
*/
public FolderSelectTree() {
tree = new Tree();
rootItem.setHTML(Util.imageItemHTML("img/menuitem_childs.gif", "root_schema", "top"));
rootItem.setStyleName("okm-TreeItem");
rootItem.setUserObject(new GWTFolder());
rootItem.setSelected(true);
@@ -115,18 +116,19 @@ public void reset() {
* Refresh asyncronous subtree branch
*/
final AsyncCallback<List<GWTFolder>> callbackGetChilds = new AsyncCallback<List<GWTFolder>>() {
@Override
public void onSuccess(List<GWTFolder> result) {
boolean directAdd = true;
// If has no childs directly add values is permited
if (actualItem.getChildCount() > 0) {
directAdd = false;
// to prevent remote folder remove it disables all tree branch
// to prevent remote folder remove it disables all tree branch
// items and after sequentially activate
hideAllBranch(actualItem);
}
// On refreshing not refreshed the actual item values but must
// On refreshing not refreshed the actual item values but must
// ensure that has childs value is consistent
if (result.isEmpty()) {
((GWTFolder) actualItem.getUserObject()).setHasChildren(false);
@@ -137,11 +139,12 @@ public void onSuccess(List<GWTFolder> result) {
// Ads folders childs if exists
for (Iterator<GWTFolder> it = result.iterator(); it.hasNext(); ) {
GWTFolder folder = it.next();
TreeItem folderItem = new TreeItem(folder.getName());
TreeItem folderItem = new TreeItem();
folderItem.setHTML(folder.getName());
folderItem.setUserObject(folder);
folderItem.setStyleName("okm-TreeItem");
// If has no childs directly add values is permited, else
// If has no childs directly add values is permited, else
// evalues each node to refresh, remove or add
if (directAdd) {
evaluesFolderIcon(folderItem);
@@ -157,6 +160,7 @@ public void onSuccess(List<GWTFolder> result) {
Main.get().mainPanel.desktop.navigator.categoriesTree.categoriesSelectPopup.status.unsetFlagChilds();
}
@Override
public void onFailure(Throwable caught) {
Main.get().mainPanel.desktop.navigator.categoriesTree.categoriesSelectPopup.status.unsetFlagChilds();
Main.get().showError("GetChilds", caught);
@@ -167,8 +171,9 @@ public void onFailure(Throwable caught) {
* Gets asyncronous root node
*/
final AsyncCallback<GWTFolder> callbackGetCategoriesFolder = new AsyncCallback<GWTFolder>() {
@Override
public void onSuccess(GWTFolder result) {
// Only executes on initalization and the actualItem is root
// Only executes on initalization and the actualItem is root
// element on initialization
//We put the id on root
actualItem.setUserObject(result);
@@ -180,6 +185,7 @@ public void onSuccess(GWTFolder result) {
getChilds(result.getPath());
}
@Override
public void onFailure(Throwable caught) {
Main.get().mainPanel.desktop.navigator.categoriesTree.categoriesSelectPopup.status.unsetFlagRoot();
Main.get().showError("GetTCategories", caught);
Oops, something went wrong.

0 comments on commit 583374d

Please sign in to comment.