"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/main/java/com/openkm/frontend/client/Main.java" between
OpenKM-document-management-system-6.3.10.tar.gz and OpenKM-document-management-system-6.3.11.tar.gz

About: OpenKM (Knowledge Management) is a document management system that allows easy management of documents, users, roles and finding your enterprise documents and records. Community version (source code).

Main.java  (OpenKM-document-management-system-6.3.10):Main.java  (OpenKM-document-management-system-6.3.11)
skipping to change at line 138 skipping to change at line 138
// User workspace properties // User workspace properties
public WorkspaceUserProperties workspaceUserProperties; public WorkspaceUserProperties workspaceUserProperties;
// Language declarations // Language declarations
private String lang; private String lang;
private Map<String, String> hI18n; private Map<String, String> hI18n;
public Map<String, String> hPropertyGroupI18n; public Map<String, String> hPropertyGroupI18n;
// The nodePath parameter // The nodePath parameter
public String fldPath = ""; // Used for folderTree because docPath is set public String fldPath = ""; // Used for folderTree because docPath is set
to null by filebroeser on this case the to null by filebrowser on this case the
// refreshing // refreshing panels are not synchronized ( loading )
// panels are not sincronized ( loading ) public String docPath = ""; // Used for folderTree because docPath is set
public String docPath = ""; // Used for folderTree because docPath is set to null by filebrowser on this case the
to null by filebroeser on this case the // refreshing panels are not synchronized ( loading )
// refreshing
// panels are not sincronized ( loading )
private String uuid = ""; private String uuid = "";
public String taskInstanceId = ""; // Used for workflowDashboard for set pending user task public String taskInstanceId = ""; // Used for workflowDashboard for set pending user task
// UI logo customer header // UI logo customer header
public boolean hasHeaderCustomization = false; public boolean hasHeaderCustomization = false;
// Main root folders and user home general values for all app // Main root folders and user home general values for all app
public GWTFolder taxonomyRootFolder; public GWTFolder taxonomyRootFolder;
public GWTFolder categoriesRootFolder; public GWTFolder categoriesRootFolder;
skipping to change at line 606 skipping to change at line 604
* *
* @return lang The language code * @return lang The language code
*/ */
public String getLang() { public String getLang() {
return lang; return lang;
} }
/** /**
* Shows popup error message ( unique entry point for error on all applic ation ) * Shows popup error message ( unique entry point for error on all applic ation )
* *
* @param okme The exception error * @param caught The exception error
*/ */
public void showError(Class<?> clazz, String callback, Throwable caught) { public void showError(Class<?> clazz, String callback, Throwable caught) {
showError(clazz + "." + callback, caught); showError(clazz + "." + callback, caught);
} }
/** /**
* Shows popup error message ( unique entry point for error on all applic ation ) * Shows popup error message ( unique entry point for error on all applic ation )
* *
* @param okm The exception error * @param caught The exception error
*/ */
public void showError(String callback, Throwable caught) { public void showError(String callback, Throwable caught) {
startUp.recoverFromError(); startUp.recoverFromError();
if (caught instanceof OKMException) { if (caught instanceof OKMException) {
OKMException okme = (OKMException) caught; OKMException okme = (OKMException) caught;
Log.error("OKMException(" + callback + "): " + okme.getCo de()); Log.error("OKMException(" + callback + "): " + okme.getCo de());
errorPopup.show(okme.getCode() + "(" + callback + "): " + i18n(okme.getCode()) + "<br><br>" + okme.getMessage()); errorPopup.show(okme.getCode() + "(" + callback + "): " + i18n(okme.getCode()) + "<br><br>" + okme.getMessage());
} else if (caught instanceof InvocationException) { } else if (caught instanceof InvocationException) {
InvocationException ie = (InvocationException) caught; InvocationException ie = (InvocationException) caught;
skipping to change at line 642 skipping to change at line 640
StatusCodeException ie = (StatusCodeException) caught; StatusCodeException ie = (StatusCodeException) caught;
Log.error("StatusCodeException(" + callback + "): " + ie + "<br/>HTTP status code error:" + ie.getStatusCode()); Log.error("StatusCodeException(" + callback + "): " + ie + "<br/>HTTP status code error:" + ie.getStatusCode());
mainPanel.bottomPanel.setStatus("status.network.error.det ected", true, ie.getStatusCode()); mainPanel.bottomPanel.setStatus("status.network.error.det ected", true, ie.getStatusCode());
} else { } else {
Log.error("UnknownException(" + callback + "): " + caught .getMessage()); Log.error("UnknownException(" + callback + "): " + caught .getMessage());
errorPopup.show(callback + ": " + caught.getMessage()); errorPopup.show(callback + ": " + caught.getMessage());
} }
} }
/** /**
* showError
*/
public void showError(String error) {
if (errorPopup != null) {
errorPopup.show(error);
} else {
showAlertError(error);
}
}
/**
* showAlertError
*/
private void showAlertError(String error) {
Window.alert("Error: " + error);
}
/**
* Gets the i18n param translation * Gets the i18n param translation
* *
* @param properties The propetie code locator * @param property The property code locator
* @return The translated value * @return The translated value
*/ */
public static String i18n(String property) { public static String i18n(String property) {
// All frontend properties starts with frontend. // All frontend properties starts with frontend.
String ret = (String) Main.get().hI18n.get("frontend." + property ); String ret = (String) Main.get().hI18n.get("frontend." + property );
if (ret == null) { if (ret == null) {
ret = property; ret = property;
} }
return ret; return ret;
} }
/** /**
* Gets the i18n extension param translation * Gets the i18n extension param translation
* *
* @param properties The propetier code locator * @param property The property code locator
* @return The translated value * @return The translated value
*/ */
public String i18nExtension(String property) { public String i18nExtension(String property) {
// All extension properties starts with extension. // All extension properties starts with extension.
String ret = (String) Main.get().hI18n.get("extension." + propert y); String ret = Main.get().hI18n.get("extension." + property);
if (ret == null) { if (ret == null) {
ret = property; ret = property;
} }
return ret; return ret;
} }
/** /**
* getExtensionUuidList * getExtensionUuidList
*
* @return
*/ */
public List<String> getExtensionUuidList() { public List<String> getExtensionUuidList() {
return extensionUuidList; return extensionUuidList;
} }
/** /**
* setExtensionUuidList * setExtensionUuidList
*
* @param extensionUuidList
*/ */
public void setExtensionUuidList(List<String> extensionUuidList) { public void setExtensionUuidList(List<String> extensionUuidList) {
this.extensionUuidList = extensionUuidList; this.extensionUuidList = extensionUuidList;
} }
@Override @Override
public void addLanguageHandlerExtension(LanguageHandlerExtension handlerE xtension) { public void addLanguageHandlerExtension(LanguageHandlerExtension handlerE xtension) {
langHandlerExtensionList.add(handlerExtension); langHandlerExtensionList.add(handlerExtension);
} }
@Override @Override
public void fireEvent(LanguageEventConstant event) { public void fireEvent(LanguageEventConstant event) {
for (Iterator<LanguageHandlerExtension> it = langHandlerExtension for (LanguageHandlerExtension languageHandlerExtension : langHand
List.iterator(); it.hasNext(); ) { lerExtensionList) {
it.next().onChange(event); languageHandlerExtension.onChange(event);
} }
} }
/** /**
* initJavaScriptApi * initJavaScriptApi
*/ */
native void initJavaScriptApi() /*-{ native void initJavaScriptApi() /*-{
// define a static JS function with a friendly name // define a static JS function with a friendly name
$wnd.i18n = function (s) { $wnd.i18n = function (s) {
return @com.openkm.frontend.client.Main::i18n(Ljava/lang/String;)(s) return @com.openkm.frontend.client.Main::i18n(Ljava/lang/
; String;)(s);
}; };
$wnd.jsI18n = function (s) { $wnd.jsI18n = function (s) {
return @com.openkm.frontend.client.Main::i18n(Ljava/lang/String;)(s) return @com.openkm.frontend.client.Main::i18n(Ljava/lang/
; String;)(s);
}; };
}-*/; }-*/;
} }
 End of changes. 11 change blocks. 
30 lines changed or deleted 42 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)