152 changed files with 1949 additions and 1419 deletions
@ -1 +1 @@ |
|||||||
package com.fr.design.report;
import com.fr.data.Verifier;
import com.fr.design.ExtraDesignClassManager;
import com.fr.design.fun.VerifyDefineProvider;
import com.fr.design.gui.controlpane.NameObjectCreator;
import com.fr.design.gui.controlpane.NameableCreator;
import com.fr.design.gui.controlpane.ObjectJControlPane;
import com.fr.design.mainframe.ElementCasePane;
import com.fr.general.Inter;
import com.fr.general.NameObject;
import com.fr.report.write.ReportWriteAttr;
import com.fr.report.write.ValueVerifier;
import com.fr.report.write.WClassVerifier;
import com.fr.stable.ArrayUtils;
import com.fr.stable.Nameable;
import java.util.ArrayList;
/**
* 校验列表
*/
public class VerifierListPane extends ObjectJControlPane {
public VerifierListPane(ElementCasePane ePane) {
super(ePane);
}
/**
* 创建选项
*
* @return 选项
*/
public NameableCreator[] createNameableCreators() {
NameableCreator[] creators = new NameableCreator[]{
new NameObjectCreator(Inter.getLocText(new String[]{"BuildIn", "Verify"}),
"/com/fr/web/images/reportlet.png",
ValueVerifier.class,
BuildInVerifierPane.class)
};
for (VerifyDefineProvider provider : ExtraDesignClassManager.getInstance().getVerifyDefineProviders()) {
creators = ArrayUtils.add(creators, new NameObjectCreator(
provider.nameForVerifier(),
provider.iconPath(),
provider.classForVerifier(),
provider.appearanceForVerifier()
) {
});
}
creators = ArrayUtils.add(creators, new NameObjectCreator(
Inter.getLocText(new String[]{"Custom", "Verify"}),
"/com/fr/web/images/reportlet.png",
WClassVerifier.class,
CustomVerifierPane.class));
return creators;
}
@Override
protected String title4PopupWindow() {
return "Verify Collections";
}
public void populate(ReportWriteAttr reportWriteAttr) {
if (reportWriteAttr == null) {
return;
}
java.util.List<NameObject> nameObjectList = new ArrayList<>();
int verifierCount = reportWriteAttr.getVerifierCount();
for (int i = 0; i < verifierCount; i++) {
Verifier verifier = reportWriteAttr.getVerifier(i);
nameObjectList.add(new NameObject(verifier.getName(), verifier));
}
this.populate(nameObjectList.toArray(new NameObject[nameObjectList.size()]));
}
public void updateReportWriteAttr(ReportWriteAttr reportWriteAttr) {
// Nameable[]居然不能强转成NameObject[],一定要这么写...
Nameable[] res = this.update();
NameObject[] res_array = new NameObject[res.length];
java.util.Arrays.asList(res).toArray(res_array);
reportWriteAttr.clearVerifiers();
for (int i = 0; i < res_array.length; i++) {
NameObject nameObject = res_array[i];
if (nameObject.getObject() instanceof Verifier) {
Verifier verifier = (Verifier) nameObject.getObject();
verifier.setName(nameObject.getName());
reportWriteAttr.addVerifier(verifier);
}
}
}
} |
package com.fr.design.report;
import com.fr.data.Verifier;
import com.fr.design.ExtraDesignClassManager;
import com.fr.design.fun.VerifyDefineProvider;
import com.fr.design.gui.controlpane.NameObjectCreator;
import com.fr.design.gui.controlpane.NameableCreator;
import com.fr.design.gui.controlpane.ObjectJControlPane;
import com.fr.design.mainframe.ElementCasePane;
import com.fr.general.Inter;
import com.fr.general.NameObject;
import com.fr.report.write.ReportWriteAttr;
import com.fr.report.write.ValueVerifier;
import com.fr.report.write.WClassVerifier;
import com.fr.stable.ArrayUtils;
import com.fr.stable.Nameable;
import java.util.ArrayList;
import java.util.Set;
/**
* 校验列表
*/
public class VerifierListPane extends ObjectJControlPane {
public VerifierListPane(ElementCasePane ePane) {
super(ePane);
}
/**
* 创建选项
*
* @return 选项
*/
public NameableCreator[] createNameableCreators() {
NameableCreator[] creators = new NameableCreator[]{
new NameObjectCreator(Inter.getLocText(new String[]{"BuildIn", "Verify"}),
"/com/fr/web/images/reportlet.png",
ValueVerifier.class,
BuildInVerifierPane.class)
};
Set<VerifyDefineProvider> set = ExtraDesignClassManager.getInstance().getArray(VerifyDefineProvider.MARK_STRING);
for (VerifyDefineProvider provider : set) {
creators = ArrayUtils.add(creators, new NameObjectCreator(
provider.nameForVerifier(),
provider.iconPath(),
provider.classForVerifier(),
provider.appearanceForVerifier()
) {
});
}
creators = ArrayUtils.add(creators, new NameObjectCreator(
Inter.getLocText(new String[]{"Custom", "Verify"}),
"/com/fr/web/images/reportlet.png",
WClassVerifier.class,
CustomVerifierPane.class));
return creators;
}
@Override
protected String title4PopupWindow() {
return "Verify Collections";
}
public void populate(ReportWriteAttr reportWriteAttr) {
if (reportWriteAttr == null) {
return;
}
java.util.List<NameObject> nameObjectList = new ArrayList<>();
int verifierCount = reportWriteAttr.getVerifierCount();
for (int i = 0; i < verifierCount; i++) {
Verifier verifier = reportWriteAttr.getVerifier(i);
nameObjectList.add(new NameObject(verifier.getName(), verifier));
}
this.populate(nameObjectList.toArray(new NameObject[nameObjectList.size()]));
}
public void updateReportWriteAttr(ReportWriteAttr reportWriteAttr) {
// Nameable[]居然不能强转成NameObject[],一定要这么写...
Nameable[] res = this.update();
NameObject[] res_array = new NameObject[res.length];
java.util.Arrays.asList(res).toArray(res_array);
reportWriteAttr.clearVerifiers();
for (int i = 0; i < res_array.length; i++) {
NameObject nameObject = res_array[i];
if (nameObject.getObject() instanceof Verifier) {
Verifier verifier = (Verifier) nameObject.getObject();
verifier.setName(nameObject.getName());
reportWriteAttr.addVerifier(verifier);
}
}
}
} |
@ -1,33 +1,10 @@ |
|||||||
<?xml version="1.0" encoding="UTF-8"?> |
<?xml version="1.0" encoding="UTF-8"?> |
||||||
<classpath> |
<classpath> |
||||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/jdk1.6u35"/> |
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/> |
||||||
<classpathentry kind="src" path="src"/> |
<classpathentry kind="src" path="src"/> |
||||||
<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/lib"/> |
<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/lib"/> |
||||||
<classpathentry combineaccessrules="false" exported="true" kind="src" path="/base"/> |
<classpathentry kind="lib" path="D:/Program Files/Git/finereport/lib/report/fr-core-8.0.jar"/> |
||||||
<classpathentry combineaccessrules="false" kind="src" path="/base-stable"/> |
<classpathentry kind="lib" path="D:/Program Files/Git/finereport/lib/report/fr-third-8.0.jar"/> |
||||||
<classpathentry combineaccessrules="false" kind="src" path="/base-basic"/> |
<classpathentry kind="lib" path="D:/Program Files/Git/finereport/lib/jetty/org.mortbay.jetty.jar"/> |
||||||
<classpathentry kind="lib" path="/lib/jetty/activation.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/commons-el.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/commons-logging.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/jasper-compiler.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/jasper-runtime.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/javax.servlet.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/jaxrpc.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/mail.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/mx4j-remote.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/mx4j-tools.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/mx4j.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/org.mortbay.jetty.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/org.mortbay.jmx.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/saaj.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/xercesImpl.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/xml-apis.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/jetty/xmlParserAPIs.jar"/> |
|
||||||
<classpathentry kind="lib" path="/lib/3rd.jar"/> |
|
||||||
<classpathentry combineaccessrules="false" kind="src" path="/base-calculate"/> |
|
||||||
<classpathentry kind="lib" path="/lib/junit.jar"/> |
|
||||||
<classpathentry combineaccessrules="false" kind="src" path="/base-data"/> |
|
||||||
<classpathentry kind="lib" path="/lib/olap4j-1.1.0.jar"/> |
|
||||||
<classpathentry combineaccessrules="false" kind="src" path="/base-file"/> |
|
||||||
<classpathentry kind="output" path="bin"/> |
<classpathentry kind="output" path="bin"/> |
||||||
</classpath> |
</classpath> |
||||||
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,74 @@ |
|||||||
|
package com.fr.design.actions.community; |
||||||
|
|
||||||
|
import java.awt.Desktop; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.io.IOException; |
||||||
|
import java.net.URI; |
||||||
|
import java.net.URISyntaxException; |
||||||
|
|
||||||
|
import javax.swing.JOptionPane; |
||||||
|
import javax.swing.KeyStroke; |
||||||
|
|
||||||
|
import com.fr.base.BaseUtils; |
||||||
|
import com.fr.base.FRContext; |
||||||
|
import com.fr.design.actions.UpdateAction; |
||||||
|
import com.fr.design.menu.MenuKeySet; |
||||||
|
import com.fr.general.Inter; |
||||||
|
import com.fr.general.SiteCenter; |
||||||
|
import com.fr.stable.StringUtils; |
||||||
|
|
||||||
|
public class BBSAction extends UpdateAction |
||||||
|
{ |
||||||
|
|
||||||
|
|
||||||
|
public BBSAction() |
||||||
|
{ |
||||||
|
this.setMenuKeySet(BBS); |
||||||
|
this.setName(getMenuKeySet().getMenuName()); |
||||||
|
this.setMnemonic(getMenuKeySet().getMnemonic()); |
||||||
|
this.setSmallIcon(BaseUtils.readIcon("/com/fr/design/images/bbs.png")); |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
* 动作 |
||||||
|
* @param e 事件 |
||||||
|
*/ |
||||||
|
@Override |
||||||
|
public void actionPerformed(ActionEvent arg0) |
||||||
|
{ |
||||||
|
String url = SiteCenter.getInstance().acquireUrlByKind("bbs"); |
||||||
|
if (StringUtils.isEmpty(url)) { |
||||||
|
FRContext.getLogger().info("The URL is empty!"); |
||||||
|
return; |
||||||
|
} |
||||||
|
try { |
||||||
|
Desktop.getDesktop().browse(new URI(url)); |
||||||
|
} catch (IOException exp) { |
||||||
|
JOptionPane.showMessageDialog(null, Inter.getLocText("Set_default_browser")); |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (URISyntaxException exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (Exception exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
FRContext.getLogger().error("Can not open the browser for URL: " + url); |
||||||
|
} |
||||||
|
} |
||||||
|
public static final MenuKeySet BBS = new MenuKeySet() { |
||||||
|
@Override |
||||||
|
public char getMnemonic() { |
||||||
|
return 'B'; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getMenuName() { |
||||||
|
return Inter.getLocText("FR-Designer_COMMUNITY_BBS"); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public KeyStroke getKeyStroke() { |
||||||
|
return null; |
||||||
|
} |
||||||
|
}; |
||||||
|
|
||||||
|
} |
@ -0,0 +1,72 @@ |
|||||||
|
package com.fr.design.actions.community; |
||||||
|
|
||||||
|
import java.awt.Desktop; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.io.IOException; |
||||||
|
import java.net.URI; |
||||||
|
import java.net.URISyntaxException; |
||||||
|
|
||||||
|
import javax.swing.JOptionPane; |
||||||
|
import javax.swing.KeyStroke; |
||||||
|
|
||||||
|
import com.fr.base.BaseUtils; |
||||||
|
import com.fr.base.FRContext; |
||||||
|
import com.fr.design.actions.UpdateAction; |
||||||
|
import com.fr.design.menu.MenuKeySet; |
||||||
|
import com.fr.general.Inter; |
||||||
|
import com.fr.general.SiteCenter; |
||||||
|
import com.fr.stable.StringUtils; |
||||||
|
|
||||||
|
public class BugAction extends UpdateAction |
||||||
|
{ |
||||||
|
|
||||||
|
public BugAction() |
||||||
|
{ this.setMenuKeySet(BUG); |
||||||
|
this.setName(getMenuKeySet().getMenuName()); |
||||||
|
this.setMnemonic(getMenuKeySet().getMnemonic()); |
||||||
|
this.setSmallIcon(BaseUtils.readIcon("/com/fr/design/images/bug.png")); |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void actionPerformed(ActionEvent arg0) |
||||||
|
{ |
||||||
|
String url = SiteCenter.getInstance().acquireUrlByKind("bbs.bugs"); |
||||||
|
if (StringUtils.isEmpty(url)) { |
||||||
|
FRContext.getLogger().info("The URL is empty!"); |
||||||
|
return; |
||||||
|
} |
||||||
|
try { |
||||||
|
Desktop.getDesktop().browse(new URI(url)); |
||||||
|
} catch (IOException exp) { |
||||||
|
JOptionPane.showMessageDialog(null, Inter.getLocText("Set_default_browser")); |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (URISyntaxException exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (Exception exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
FRContext.getLogger().error("Can not open the browser for URL: " + url); |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
|
public static final MenuKeySet BUG = new MenuKeySet() { |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getMenuName() { |
||||||
|
return Inter.getLocText("FR-Designer_COMMUNITY_BUG"); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public KeyStroke getKeyStroke() { |
||||||
|
return null; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public char getMnemonic() |
||||||
|
{ |
||||||
|
|
||||||
|
return 'U'; |
||||||
|
} |
||||||
|
}; |
||||||
|
|
||||||
|
} |
@ -0,0 +1,70 @@ |
|||||||
|
package com.fr.design.actions.community; |
||||||
|
|
||||||
|
import java.awt.Desktop; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.io.IOException; |
||||||
|
import java.net.URI; |
||||||
|
import java.net.URISyntaxException; |
||||||
|
|
||||||
|
import javax.swing.JOptionPane; |
||||||
|
import javax.swing.KeyStroke; |
||||||
|
|
||||||
|
import com.fr.base.BaseUtils; |
||||||
|
import com.fr.base.FRContext; |
||||||
|
import com.fr.design.actions.UpdateAction; |
||||||
|
import com.fr.design.menu.MenuKeySet; |
||||||
|
import com.fr.general.Inter; |
||||||
|
import com.fr.general.SiteCenter; |
||||||
|
import com.fr.stable.StringUtils; |
||||||
|
|
||||||
|
public class NeedAction extends UpdateAction |
||||||
|
{ |
||||||
|
|
||||||
|
public NeedAction() |
||||||
|
{ |
||||||
|
this.setMenuKeySet(NEED); |
||||||
|
this.setName(getMenuKeySet().getMenuName()); |
||||||
|
this.setMnemonic(getMenuKeySet().getMnemonic()); |
||||||
|
this.setSmallIcon(BaseUtils.readIcon("/com/fr/design/images/need.png")); |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void actionPerformed(ActionEvent arg0) |
||||||
|
{ |
||||||
|
String url = SiteCenter.getInstance().acquireUrlByKind("bbs.needs"); |
||||||
|
if (StringUtils.isEmpty(url)) { |
||||||
|
FRContext.getLogger().info("The URL is empty!"); |
||||||
|
return; |
||||||
|
} |
||||||
|
try { |
||||||
|
Desktop.getDesktop().browse(new URI(url)); |
||||||
|
} catch (IOException exp) { |
||||||
|
JOptionPane.showMessageDialog(null, Inter.getLocText("Set_default_browser")); |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (URISyntaxException exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (Exception exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
FRContext.getLogger().error("Can not open the browser for URL: " + url); |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
|
public static final MenuKeySet NEED = new MenuKeySet() { |
||||||
|
@Override |
||||||
|
public char getMnemonic() { |
||||||
|
return 'N'; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getMenuName() { |
||||||
|
return Inter.getLocText("FR-Designer_COMMUNITY_NEED"); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public KeyStroke getKeyStroke() { |
||||||
|
return null; |
||||||
|
} |
||||||
|
}; |
||||||
|
|
||||||
|
} |
@ -0,0 +1,69 @@ |
|||||||
|
package com.fr.design.actions.community; |
||||||
|
|
||||||
|
import java.awt.Desktop; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.io.IOException; |
||||||
|
import java.net.URI; |
||||||
|
import java.net.URISyntaxException; |
||||||
|
|
||||||
|
import javax.swing.JOptionPane; |
||||||
|
import javax.swing.KeyStroke; |
||||||
|
|
||||||
|
import com.fr.base.BaseUtils; |
||||||
|
import com.fr.base.FRContext; |
||||||
|
import com.fr.design.actions.UpdateAction; |
||||||
|
import com.fr.design.menu.MenuKeySet; |
||||||
|
import com.fr.general.Inter; |
||||||
|
import com.fr.general.SiteCenter; |
||||||
|
import com.fr.stable.StringUtils; |
||||||
|
|
||||||
|
public class QuestionAction extends UpdateAction |
||||||
|
{ |
||||||
|
|
||||||
|
public QuestionAction() |
||||||
|
{ this.setMenuKeySet(QUESTIONS); |
||||||
|
this.setName(getMenuKeySet().getMenuName()); |
||||||
|
this.setMnemonic(getMenuKeySet().getMnemonic()); |
||||||
|
this.setSmallIcon(BaseUtils.readIcon("/com/fr/design/images/questions.png")); |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void actionPerformed(ActionEvent arg0) |
||||||
|
{ |
||||||
|
String url = SiteCenter.getInstance().acquireUrlByKind("bbs.questions"); |
||||||
|
if (StringUtils.isEmpty(url)) { |
||||||
|
FRContext.getLogger().info("The URL is empty!"); |
||||||
|
return; |
||||||
|
} |
||||||
|
try { |
||||||
|
Desktop.getDesktop().browse(new URI(url)); |
||||||
|
} catch (IOException exp) { |
||||||
|
JOptionPane.showMessageDialog(null, Inter.getLocText("Set_default_browser")); |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (URISyntaxException exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (Exception exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
FRContext.getLogger().error("Can not open the browser for URL: " + url); |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
|
public static final MenuKeySet QUESTIONS = new MenuKeySet() { |
||||||
|
@Override |
||||||
|
public char getMnemonic() { |
||||||
|
return 'Q'; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getMenuName() { |
||||||
|
return Inter.getLocText("FR-Designer_COMMUNITY_QUESTIONS"); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public KeyStroke getKeyStroke() { |
||||||
|
return null; |
||||||
|
} |
||||||
|
}; |
||||||
|
|
||||||
|
} |
@ -0,0 +1,70 @@ |
|||||||
|
package com.fr.design.actions.community; |
||||||
|
|
||||||
|
import java.awt.Desktop; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.io.IOException; |
||||||
|
import java.net.URI; |
||||||
|
import java.net.URISyntaxException; |
||||||
|
|
||||||
|
import javax.swing.JOptionPane; |
||||||
|
import javax.swing.KeyStroke; |
||||||
|
|
||||||
|
import com.fr.base.BaseUtils; |
||||||
|
import com.fr.base.FRContext; |
||||||
|
import com.fr.design.actions.UpdateAction; |
||||||
|
import com.fr.design.menu.MenuKeySet; |
||||||
|
import com.fr.general.Inter; |
||||||
|
import com.fr.general.SiteCenter; |
||||||
|
import com.fr.stable.StringUtils; |
||||||
|
|
||||||
|
public class SignAction extends UpdateAction |
||||||
|
{ |
||||||
|
|
||||||
|
public SignAction() |
||||||
|
{ |
||||||
|
this.setMenuKeySet(SIGN); |
||||||
|
this.setName(getMenuKeySet().getMenuName()); |
||||||
|
this.setMnemonic(getMenuKeySet().getMnemonic()); |
||||||
|
this.setSmallIcon(BaseUtils.readIcon("/com/fr/design/images/signature.png")); |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void actionPerformed(ActionEvent arg0) |
||||||
|
{ |
||||||
|
String url = SiteCenter.getInstance().acquireUrlByKind("bbs.aut"); |
||||||
|
if (StringUtils.isEmpty(url)) { |
||||||
|
FRContext.getLogger().info("The URL is empty!"); |
||||||
|
return; |
||||||
|
} |
||||||
|
try { |
||||||
|
Desktop.getDesktop().browse(new URI(url)); |
||||||
|
} catch (IOException exp) { |
||||||
|
JOptionPane.showMessageDialog(null, Inter.getLocText("Set_default_browser")); |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (URISyntaxException exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (Exception exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
FRContext.getLogger().error("Can not open the browser for URL: " + url); |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
|
public static final MenuKeySet SIGN = new MenuKeySet() { |
||||||
|
@Override |
||||||
|
public char getMnemonic() { |
||||||
|
return 'S'; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getMenuName() { |
||||||
|
return Inter.getLocText("FR-Designer_COMMUNITY_SIGN"); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public KeyStroke getKeyStroke() { |
||||||
|
return null; |
||||||
|
} |
||||||
|
}; |
||||||
|
|
||||||
|
} |
@ -0,0 +1,70 @@ |
|||||||
|
package com.fr.design.actions.community; |
||||||
|
|
||||||
|
import java.awt.Desktop; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.io.IOException; |
||||||
|
import java.net.URI; |
||||||
|
import java.net.URISyntaxException; |
||||||
|
|
||||||
|
import javax.swing.JOptionPane; |
||||||
|
import javax.swing.KeyStroke; |
||||||
|
|
||||||
|
import com.fr.base.BaseUtils; |
||||||
|
import com.fr.base.FRContext; |
||||||
|
import com.fr.design.actions.UpdateAction; |
||||||
|
import com.fr.design.menu.MenuKeySet; |
||||||
|
import com.fr.general.Inter; |
||||||
|
import com.fr.general.SiteCenter; |
||||||
|
import com.fr.stable.StringUtils; |
||||||
|
|
||||||
|
public class UpAction extends UpdateAction |
||||||
|
{ |
||||||
|
|
||||||
|
public UpAction() |
||||||
|
{ |
||||||
|
this.setMenuKeySet(UPDATE); |
||||||
|
this.setName(getMenuKeySet().getMenuName()); |
||||||
|
this.setMnemonic(getMenuKeySet().getMnemonic()); |
||||||
|
this.setSmallIcon(BaseUtils.readIcon("/com/fr/design/images/update.png")); |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void actionPerformed(ActionEvent arg0) |
||||||
|
{ |
||||||
|
String url = SiteCenter.getInstance().acquireUrlByKind("bbs.update"); |
||||||
|
if (StringUtils.isEmpty(url)) { |
||||||
|
FRContext.getLogger().info("The URL is empty!"); |
||||||
|
return; |
||||||
|
} |
||||||
|
try { |
||||||
|
Desktop.getDesktop().browse(new URI(url)); |
||||||
|
} catch (IOException exp) { |
||||||
|
JOptionPane.showMessageDialog(null, Inter.getLocText("Set_default_browser")); |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (URISyntaxException exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (Exception exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
FRContext.getLogger().error("Can not open the browser for URL: " + url); |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
|
public static final MenuKeySet UPDATE = new MenuKeySet() { |
||||||
|
@Override |
||||||
|
public char getMnemonic() { |
||||||
|
return 'U'; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getMenuName() { |
||||||
|
return Inter.getLocText("FR-Designer_COMMUNITY_UPDATE"); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public KeyStroke getKeyStroke() { |
||||||
|
return null; |
||||||
|
} |
||||||
|
}; |
||||||
|
|
||||||
|
} |
@ -0,0 +1,70 @@ |
|||||||
|
package com.fr.design.actions.community; |
||||||
|
|
||||||
|
import java.awt.Desktop; |
||||||
|
import java.awt.event.ActionEvent; |
||||||
|
import java.io.IOException; |
||||||
|
import java.net.URI; |
||||||
|
import java.net.URISyntaxException; |
||||||
|
|
||||||
|
import javax.swing.JOptionPane; |
||||||
|
import javax.swing.KeyStroke; |
||||||
|
|
||||||
|
import com.fr.base.BaseUtils; |
||||||
|
import com.fr.base.FRContext; |
||||||
|
import com.fr.design.actions.UpdateAction; |
||||||
|
import com.fr.design.menu.MenuKeySet; |
||||||
|
import com.fr.general.Inter; |
||||||
|
import com.fr.general.SiteCenter; |
||||||
|
import com.fr.stable.StringUtils; |
||||||
|
|
||||||
|
public class VideoAction extends UpdateAction |
||||||
|
{ |
||||||
|
|
||||||
|
public VideoAction() |
||||||
|
{ |
||||||
|
this.setMenuKeySet(VIDEO); |
||||||
|
this.setName(getMenuKeySet().getMenuName()); |
||||||
|
this.setMnemonic(getMenuKeySet().getMnemonic()); |
||||||
|
this.setSmallIcon(BaseUtils.readIcon("/com/fr/design/images/video.png")); |
||||||
|
|
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void actionPerformed(ActionEvent arg0) |
||||||
|
{ |
||||||
|
String url = SiteCenter.getInstance().acquireUrlByKind("bbs.video"); |
||||||
|
if (StringUtils.isEmpty(url)) { |
||||||
|
FRContext.getLogger().info("The URL is empty!"); |
||||||
|
return; |
||||||
|
} |
||||||
|
try { |
||||||
|
Desktop.getDesktop().browse(new URI(url)); |
||||||
|
} catch (IOException exp) { |
||||||
|
JOptionPane.showMessageDialog(null, Inter.getLocText("Set_default_browser")); |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (URISyntaxException exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
} catch (Exception exp) { |
||||||
|
FRContext.getLogger().errorWithServerLevel(exp.getMessage(), exp); |
||||||
|
FRContext.getLogger().error("Can not open the browser for URL: " + url); |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
|
public static final MenuKeySet VIDEO = new MenuKeySet() { |
||||||
|
@Override |
||||||
|
public char getMnemonic() { |
||||||
|
return 'V'; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getMenuName() { |
||||||
|
return Inter.getLocText("FR-Designer_COMMUNITY_VIDEO"); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public KeyStroke getKeyStroke() { |
||||||
|
return null; |
||||||
|
} |
||||||
|
}; |
||||||
|
|
||||||
|
} |
@ -1,23 +1,48 @@ |
|||||||
package com.fr.design.fun; |
package com.fr.design.fun; |
||||||
|
|
||||||
import com.fr.design.report.AbstractExportPane; |
import com.fr.design.report.AbstractExportPane; |
||||||
import com.fr.stable.fun.Level; |
import com.fr.stable.fun.mark.Mutable; |
||||||
|
|
||||||
import javax.swing.*; |
import javax.swing.*; |
||||||
|
|
||||||
/** |
/** |
||||||
* Created by vito on 16/5/5. |
* Created by vito on 16/5/5. |
||||||
*/ |
*/ |
||||||
public interface ExportAttrTabProvider extends Level{ |
|
||||||
|
/** |
||||||
|
* 导出属性Tab页的接口 |
||||||
|
*/ |
||||||
|
public interface ExportAttrTabProvider extends Mutable { |
||||||
String XML_TAG = "ExportAttrTabProvider"; |
String XML_TAG = "ExportAttrTabProvider"; |
||||||
|
|
||||||
int CURRENT_LEVEL = 1; |
int CURRENT_LEVEL = 1; |
||||||
|
|
||||||
|
/** |
||||||
|
* 转换成SwingComponent |
||||||
|
* |
||||||
|
* @return JComponent |
||||||
|
*/ |
||||||
JComponent toSwingComponent(); |
JComponent toSwingComponent(); |
||||||
|
|
||||||
|
/** |
||||||
|
* 转换成AbstractExportPane |
||||||
|
* |
||||||
|
* @return AbstractExportPane |
||||||
|
*/ |
||||||
AbstractExportPane toExportPane(); |
AbstractExportPane toExportPane(); |
||||||
|
|
||||||
|
/** |
||||||
|
* tab的标题 |
||||||
|
* |
||||||
|
* @return |
||||||
|
*/ |
||||||
String title(); |
String title(); |
||||||
|
|
||||||
|
/** |
||||||
|
* tag标签 |
||||||
|
* |
||||||
|
* @return tag名称 |
||||||
|
* @deprecated 将来不使用tag作为区分 |
||||||
|
*/ |
||||||
String tag(); |
String tag(); |
||||||
} |
} |
||||||
|
@ -0,0 +1,22 @@ |
|||||||
|
package com.fr.design.fun; |
||||||
|
|
||||||
|
import com.fr.form.ui.Widget; |
||||||
|
import com.fr.stable.fun.mark.Immutable; |
||||||
|
|
||||||
|
/** |
||||||
|
* Coder: zack |
||||||
|
* Date: 2016/5/12 |
||||||
|
* Time: 10:37 |
||||||
|
*/ |
||||||
|
public interface WidgetDesignHandler extends Immutable { |
||||||
|
String XML_TAG = "WidgetDesignHandler"; |
||||||
|
int CURRENT_LEVEL = 1; |
||||||
|
|
||||||
|
/** |
||||||
|
* 传递控件共有属性 |
||||||
|
* |
||||||
|
* @param oldWidget 老控件 |
||||||
|
* @param newWidget 新控件 |
||||||
|
*/ |
||||||
|
void transferWidgetProperties(Widget oldWidget, Widget newWidget); |
||||||
|
} |
@ -1,17 +1,23 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.CellWidgetOptionProvider; |
import com.fr.design.fun.CellWidgetOptionProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* @author richie |
* @author richie |
||||||
* @date 2015-05-13 |
* @date 2015-05-13 |
||||||
* @since 8.0 |
* @since 8.0 |
||||||
*/ |
*/ |
||||||
public abstract class AbstractCellWidgetOptionProvider implements CellWidgetOptionProvider { |
@API(level = CellWidgetOptionProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractCellWidgetOptionProvider extends AbstractProvider implements CellWidgetOptionProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,16 +1,24 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.ConnectionProvider; |
import com.fr.design.fun.ConnectionProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* @author richie |
* @author richie |
||||||
* @date 2015-05-13 |
* @date 2015-05-13 |
||||||
* @since 8.0 |
* @since 8.0 |
||||||
*/ |
*/ |
||||||
public abstract class AbstractConnectionProvider implements ConnectionProvider { |
@API(level = ConnectionProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractConnectionProvider extends AbstractProvider implements ConnectionProvider { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,15 +1,21 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.GlobalListenerProvider; |
import com.fr.design.fun.GlobalListenerProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* Created by zack on 2015/8/17. |
* Created by zack on 2015/8/17. |
||||||
*/ |
*/ |
||||||
public abstract class AbstractGlobalListenerProvider implements GlobalListenerProvider { |
@API(level = GlobalListenerProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractGlobalListenerProvider extends AbstractProvider implements GlobalListenerProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,16 +1,23 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.HighlightProvider; |
import com.fr.design.fun.HighlightProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* @author richie |
* @author richie |
||||||
* @date 2015-05-13 |
* @date 2015-05-13 |
||||||
* @since 8.0 |
* @since 8.0 |
||||||
*/ |
*/ |
||||||
public abstract class AbstractHighlightProvider implements HighlightProvider { |
@API(level = HighlightProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractHighlightProvider extends AbstractProvider implements HighlightProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,14 +1,21 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.HyperlinkProvider; |
import com.fr.design.fun.HyperlinkProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* Created by zack on 2016/1/18. |
* Created by zack on 2016/1/18. |
||||||
*/ |
*/ |
||||||
public abstract class AbstractHyperlinkProvider implements HyperlinkProvider { |
@API(level = HyperlinkProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractHyperlinkProvider extends AbstractProvider implements HyperlinkProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,14 +1,21 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.JavaScriptActionProvider; |
import com.fr.design.fun.JavaScriptActionProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* Created by zack on 2015/8/20. |
* Created by zack on 2015/8/20. |
||||||
*/ |
*/ |
||||||
public abstract class AbstractJavaScriptActionProvider implements JavaScriptActionProvider { |
@API(level = JavaScriptActionProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractJavaScriptActionProvider extends AbstractProvider implements JavaScriptActionProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,16 +1,23 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.ParameterWidgetOptionProvider; |
import com.fr.design.fun.ParameterWidgetOptionProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* @author richie |
* @author richie |
||||||
* @date 2015-05-13 |
* @date 2015-05-13 |
||||||
* @since 8.0 |
* @since 8.0 |
||||||
*/ |
*/ |
||||||
public abstract class AbstractParameterWidgetOptionProvider implements ParameterWidgetOptionProvider { |
@API(level = ParameterWidgetOptionProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractParameterWidgetOptionProvider extends AbstractProvider implements ParameterWidgetOptionProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,17 +1,23 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.PresentKindProvider; |
import com.fr.design.fun.PresentKindProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* @author richie |
* @author richie |
||||||
* @date 2015-05-22 |
* @date 2015-05-22 |
||||||
* @since 8.0 |
* @since 8.0 |
||||||
*/ |
*/ |
||||||
public abstract class AbstractPresentKindProvider implements PresentKindProvider { |
@API(level = PresentKindProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractPresentKindProvider extends AbstractProvider implements PresentKindProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,12 +1,39 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
|
import com.fr.design.data.datapane.TableDataNameObjectCreator; |
||||||
|
import com.fr.design.data.tabledata.wrapper.TableDataFactory; |
||||||
import com.fr.design.fun.ServerTableDataDefineProvider; |
import com.fr.design.fun.ServerTableDataDefineProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* @author richie |
* @author richie |
||||||
* @date 2015-05-13 |
* @date 2015-05-13 |
||||||
* @since 8.0 |
* @since 8.0 |
||||||
*/ |
*/ |
||||||
public abstract class AbstractServerTableDataDefineProvider implements ServerTableDataDefineProvider { |
@API(level = ServerTableDataDefineProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractServerTableDataDefineProvider extends AbstractProvider implements ServerTableDataDefineProvider { |
||||||
|
|
||||||
|
@Override |
||||||
|
public int currentAPILevel() { |
||||||
|
return CURRENT_LEVEL; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void process() { |
||||||
|
TableDataNameObjectCreator creator = new TableDataNameObjectCreator( |
||||||
|
nameForTableData(), |
||||||
|
prefixForTableData(), |
||||||
|
iconPathForTableData(), |
||||||
|
classForTableData(), |
||||||
|
classForInitTableData(), |
||||||
|
appearanceForTableData() |
||||||
|
); |
||||||
|
TableDataFactory.register(classForTableData(), creator); |
||||||
|
} |
||||||
} |
} |
@ -1,12 +1,18 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.SubmitProvider; |
import com.fr.design.fun.SubmitProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
public abstract class AbstractSubmitProvider implements SubmitProvider { |
@API(level = SubmitProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractSubmitProvider extends AbstractProvider implements SubmitProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -1,16 +1,39 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
|
import com.fr.design.data.datapane.TableDataNameObjectCreator; |
||||||
|
import com.fr.design.data.tabledata.wrapper.TableDataFactory; |
||||||
import com.fr.design.fun.TableDataDefineProvider; |
import com.fr.design.fun.TableDataDefineProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* @author richie |
* @author richie |
||||||
* @date 2015-05-13 |
* @date 2015-05-13 |
||||||
* @since 8.0 |
* @since 8.0 |
||||||
*/ |
*/ |
||||||
public abstract class AbstractTableDataDefineProvider implements TableDataDefineProvider { |
@API(level = TableDataDefineProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractTableDataDefineProvider extends AbstractProvider implements TableDataDefineProvider { |
||||||
|
|
||||||
@Override |
@Override |
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public void process() { |
||||||
|
TableDataNameObjectCreator creator = new TableDataNameObjectCreator( |
||||||
|
nameForTableData(), |
||||||
|
prefixForTableData(), |
||||||
|
iconPathForTableData(), |
||||||
|
classForTableData(), |
||||||
|
classForInitTableData(), |
||||||
|
appearanceForTableData() |
||||||
|
); |
||||||
|
TableDataFactory.register(classForTableData(), creator); |
||||||
|
} |
||||||
} |
} |
@ -1,14 +1,21 @@ |
|||||||
package com.fr.design.fun.impl; |
package com.fr.design.fun.impl; |
||||||
|
|
||||||
import com.fr.design.fun.ToolbarItemProvider; |
import com.fr.design.fun.ToolbarItemProvider; |
||||||
|
import com.fr.stable.fun.impl.AbstractProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
/** |
/** |
||||||
* Created by richie on 15/12/1. |
* Created by richie on 15/12/1. |
||||||
*/ |
*/ |
||||||
public abstract class AbstractToolbarItem implements ToolbarItemProvider { |
@API(level = ToolbarItemProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractToolbarItem extends AbstractProvider implements ToolbarItemProvider { |
||||||
|
|
||||||
public int currentAPILevel() { |
public int currentAPILevel() { |
||||||
return CURRENT_LEVEL; |
return CURRENT_LEVEL; |
||||||
} |
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
} |
} |
@ -0,0 +1,18 @@ |
|||||||
|
package com.fr.design.fun.impl; |
||||||
|
|
||||||
|
import com.fr.design.fun.WidgetDesignHandler; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
|
/** |
||||||
|
* Coder: zack |
||||||
|
* Date: 2016/5/12 |
||||||
|
* Time: 10:41 |
||||||
|
*/ |
||||||
|
@API(level = WidgetDesignHandler.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractWidgetDesignHandler implements WidgetDesignHandler { |
||||||
|
|
||||||
|
@Override |
||||||
|
public int currentAPILevel() { |
||||||
|
return CURRENT_LEVEL; |
||||||
|
} |
||||||
|
} |
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue