本文整理汇总了Java中org.pentaho.ui.xul.XulLoader类的典型用法代码示例。如果您正苦于以下问题:Java XulLoader类的具体用法?Java XulLoader怎么用?Java XulLoader使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
XulLoader类属于org.pentaho.ui.xul包,在下文中一共展示了XulLoader类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = new XulSpoonResourceBundle(Spoon.class);
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("import-rules-toolbar"); //$NON-NLS-1$
ToolBar swtToolbar = (ToolBar) toolbar.getManagedObject();
swtToolbar.layout(true, true);
} catch (Throwable t) {
LogChannel.GENERAL.logError(Const.getStackTracker(t));
new ErrorDialog(shell,
BaseMessages.getString(PKG, "ImportRulesDialog.Exception.ErrorReadingXULFile.Title"), //$NON-NLS-1$
BaseMessages.getString(PKG, "ImportRulesDialog.Exception.ErrorReadingXULFile.Message", XUL_FILE_TOOLBAR), new Exception(t)); //$NON-NLS-1$
}
}
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:20,代码来源:ImportRulesDialog.java
示例2: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = new XulSpoonResourceBundle(Spoon.class);
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_TRANS_LOG_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("nav-toolbar"); //$NON-NLS-1$
ToolBar swtToolbar = (ToolBar) toolbar.getManagedObject();
swtToolbar.layout(true, true);
} catch (Throwable t) {
log.logError(Const.getStackTracker(t));
new ErrorDialog(jobLogComposite.getShell(), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Title"), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_LOG_TOOLBAR), new Exception(t)); //$NON-NLS-1$ //$NON-NLS-2$
}
}
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:18,代码来源:JobLogDelegate.java
示例3: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = new XulSpoonResourceBundle(Spoon.class);
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_TRANS_GRID_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("nav-toolbar"); //$NON-NLS-1$
refreshButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById("refresh-history"); //$NON-NLS-1$
fetchNextBatchButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById("fetch-next-batch-history"); //$NON-NLS-1$
fetchAllButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById("fetch-all-history"); //$NON-NLS-1$
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
swtToolBar.layout(true, true);
} catch (Throwable t) {
log.logError(Const.getStackTracker(t));
new ErrorDialog(jobHistoryComposite.getShell(), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Title"), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_GRID_TOOLBAR), new Exception(t)); //$NON-NLS-1$//$NON-NLS-2$
}
}
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:22,代码来源:JobHistoryDelegate.java
示例4: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = GlobalMessages.getBundle("org/pentaho/di/ui/spoon/messages/messages");
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_TRANS_GRID_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("nav-toolbar");
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
swtToolBar.layout(true, true);
} catch (Throwable t) {
log.logError(toString(), Const.getStackTracker(t));
new ErrorDialog(transGridComposite.getShell(), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Title"), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_GRID_TOOLBAR), new Exception(t));
}
}
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:18,代码来源:TransGridDelegate.java
示例5: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = new XulSpoonResourceBundle(Spoon.class);
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_TRANS_GRID_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("nav-toolbar"); //$NON-NLS-1$
refreshButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById("refresh-history"); //$NON-NLS-1$
fetchNextBatchButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById("fetch-next-batch-history"); //$NON-NLS-1$
fetchAllButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById("fetch-all-history"); //$NON-NLS-1$
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
swtToolBar.layout(true, true);
} catch (Throwable t) {
log.logError(Const.getStackTracker(t));
new ErrorDialog(transHistoryComposite.getShell(), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Title"), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_GRID_TOOLBAR), new Exception(t)); //$NON-NLS-1$ //$NON-NLS-2$
}
}
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:22,代码来源:TransHistoryDelegate.java
示例6: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = new XulSpoonResourceBundle(Spoon.class);
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_TRANS_LOG_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("nav-toolbar"); //$NON-NLS-1$
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
swtToolBar.layout(true, true);
} catch (Throwable t) {
log.logError(Const.getStackTracker(t));
new ErrorDialog(transLogComposite.getShell(), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Title"), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_LOG_TOOLBAR), new Exception(t)); //$NON-NLS-1$ //$NON-NLS-2$
}
}
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:18,代码来源:TransLogDelegate.java
示例7: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = GlobalMessages.getBundle("org/pentaho/di/ui/spoon/messages/messages");
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_TRANS_PREVIEW_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("nav-toolbar");
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
swtToolBar.layout(true, true);
} catch (Throwable t) {
log.logError(toString(), Const.getStackTracker(t));
new ErrorDialog(transPreviewComposite.getShell(), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Title"),
BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_PREVIEW_TOOLBAR), new Exception(t));
}
}
开发者ID:jjeb,项目名称:kettle-trunk,代码行数:19,代码来源:TransPreviewDelegate.java
示例8: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new KettleXulLoader();
loader.setSettingsManager( XulSpoonSettingsManager.getInstance() );
ResourceBundle bundle = new XulSpoonResourceBundle( Spoon.class );
XulDomContainer xulDomContainer = loader.loadXul( XUL_FILE_TOOLBAR, bundle );
xulDomContainer.addEventHandler( this );
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById( "import-rules-toolbar" );
ToolBar swtToolbar = (ToolBar) toolbar.getManagedObject();
swtToolbar.layout( true, true );
} catch ( Throwable t ) {
LogChannel.GENERAL.logError( Const.getStackTracker( t ) );
new ErrorDialog( shell,
BaseMessages.getString( PKG, "ImportRulesDialog.Exception.ErrorReadingXULFile.Title" ),
BaseMessages.getString( PKG, "ImportRulesDialog.Exception.ErrorReadingXULFile.Message", XUL_FILE_TOOLBAR ),
new Exception( t ) );
}
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:21,代码来源:ImportRulesDialog.java
示例9: initializeXul
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
protected void initializeXul( XulLoader loader, BindingFactory bindingFactory, XulRunner runner, Object parent ) throws XulException {
bf = bindingFactory;
this.runner = runner;
loader.registerClassLoader( getClass().getClassLoader() );
loader.setSettingsManager( getSettingsManager() );
loader.setOuterContext( parent );
container = loader.loadXul( xulFile, getResourceBundle() );
bf.setDocument( container.getDocumentRoot() );
for ( XulEventHandler h : getEventHandlers() ) {
container.addEventHandler( h );
}
this.runner.addContainer( container );
// try and get the dialog
xulDialog = (XulDialog) container.getDocumentRoot().getRootElement();
runner.initialize();
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:24,代码来源:AbstractPreviewRowsXulDialog.java
示例10: initializeXul
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
protected void initializeXul( XulLoader loader, BindingFactory bindingFactory, XulRunner runner, Object parent ) throws XulException {
bf = bindingFactory;
this.runner = runner;
loader.registerClassLoader( getClass().getClassLoader() );
loader.setSettingsManager( getSettingsManager() );
loader.setOuterContext( parent );
container = loader.loadXul( xulFile, getResourceBundle() );
bf.setDocument( container.getDocumentRoot() );
for ( XulEventHandler h : getEventHandlers() ) {
container.addEventHandler( h );
}
this.runner.addContainer( container );
// try and get the dialog
xulDialog = (XulDialog) container.getDocumentRoot().getRootElement();
runner.initialize();
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:20,代码来源:BaseStepGenericXulDialog.java
示例11: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new KettleXulLoader();
loader.setSettingsManager( XulSpoonSettingsManager.getInstance() );
ResourceBundle bundle = new XulSpoonResourceBundle( Spoon.class );
XulDomContainer xulDomContainer = loader.loadXul( XUL_FILE_TRANS_LOG_TOOLBAR, bundle );
xulDomContainer.addEventHandler( this );
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById( "nav-toolbar" );
ToolBar swtToolbar = (ToolBar) toolbar.getManagedObject();
spoon.props.setLook( swtToolbar, Props.WIDGET_STYLE_TOOLBAR );
swtToolbar.layout( true, true );
} catch ( Throwable t ) {
log.logError( Const.getStackTracker( t ) );
new ErrorDialog( jobLogComposite.getShell(),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Title" ),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_LOG_TOOLBAR ),
new Exception( t ) );
}
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:22,代码来源:JobLogDelegate.java
示例12: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new KettleXulLoader();
loader.setSettingsManager( XulSpoonSettingsManager.getInstance() );
ResourceBundle bundle = new XulSpoonResourceBundle( Spoon.class );
XulDomContainer xulDomContainer = loader.loadXul( XUL_FILE_TRANS_GRID_TOOLBAR, bundle );
xulDomContainer.addEventHandler( this );
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById( "nav-toolbar" );
refreshButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById( "refresh-history" );
fetchNextBatchButton =
(XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById( "fetch-next-batch-history" );
fetchAllButton = (XulToolbarbutton) xulDomContainer.getDocumentRoot().getElementById( "fetch-all-history" );
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
spoon.props.setLook( swtToolBar, Props.WIDGET_STYLE_TOOLBAR );
swtToolBar.layout( true, true );
} catch ( Throwable t ) {
log.logError( Const.getStackTracker( t ) );
new ErrorDialog( jobHistoryComposite.getShell(),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Title" ),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_GRID_TOOLBAR ),
new Exception( t ) );
}
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:26,代码来源:JobHistoryDelegate.java
示例13: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new KettleXulLoader();
loader.setSettingsManager( XulSpoonSettingsManager.getInstance() );
ResourceBundle bundle = GlobalMessages.getBundle( "org/pentaho/di/ui/spoon/messages/messages" );
XulDomContainer xulDomContainer = loader.loadXul( XUL_FILE_TRANS_GRID_TOOLBAR, bundle );
xulDomContainer.addEventHandler( this );
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById( "nav-toolbar" );
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
spoon.props.setLook( swtToolBar, Props.WIDGET_STYLE_TOOLBAR );
swtToolBar.layout( true, true );
} catch ( Throwable t ) {
log.logError( toString(), Const.getStackTracker( t ) );
new ErrorDialog( transGridComposite.getShell(),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Title" ),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_GRID_TOOLBAR ),
new Exception( t ) );
}
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:22,代码来源:TransGridDelegate.java
示例14: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new KettleXulLoader();
loader.setSettingsManager( XulSpoonSettingsManager.getInstance() );
ResourceBundle bundle = new XulSpoonResourceBundle( Spoon.class );
XulDomContainer xulDomContainer = loader.loadXul( XUL_FILE_TRANS_LOG_TOOLBAR, bundle );
xulDomContainer.addEventHandler( this );
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById( "nav-toolbar" );
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
spoon.props.setLook( swtToolBar, Props.WIDGET_STYLE_TOOLBAR );
swtToolBar.layout( true, true );
} catch ( Throwable t ) {
log.logError( Const.getStackTracker( t ) );
new ErrorDialog( transLogComposite.getShell(),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Title" ),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_LOG_TOOLBAR ),
new Exception( t ) );
}
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:22,代码来源:TransLogDelegate.java
示例15: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
protected void addToolBar() {
try {
XulLoader loader = new SwtXulLoader();
loader.setSettingsManager(XulSpoonSettingsManager.getInstance());
ResourceBundle bundle = GlobalMessages.getBundle("org/pentaho/di/ui/spoon/messages/messages");
XulDomContainer xulDomContainer = loader.loadXul(XUL_FILE_BROWSER_TOOLBAR, bundle);
xulDomContainer.addEventHandler(this);
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById("nav-toolbar");
@SuppressWarnings("unused")
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
// Add a URL
back = (XulToolbarbutton) toolbar.getElementById("browse-back");
back.setDisabled(true);
forward = (XulToolbarbutton) toolbar.getElementById("browse-forward");
forward.setLabel(BaseMessages.getString(PKG, "SpoonBrowser.Dialog.Forward"));
forward.setDisabled(false);
location = (XulTextbox) toolbar.getElementById("browser-address");
Control toolbarControl = (Control) toolbar.getManagedObject();
toolbarControl.setLayoutData(new FormData());
toolbarControl.setParent(composite);
} catch (Exception e) {
e.printStackTrace();
new ErrorDialog(shell, BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Title"), BaseMessages.getString(PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_BROWSER_TOOLBAR), e);
}
}
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:30,代码来源:SpoonBrowser.java
示例16: init
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void init() {
try {
XulLoader loader = getLoader();
loader.setOuterContext( parentWindow );
container = loader.loadXul( "org/pentaho/commons/metadata/mqleditor/editor/xul/mainFrame.xul" );
getRunner().addContainer( container );
BindingFactory bf = new DefaultBindingFactory();
bf.setDocument( container.getDocumentRoot() );
mainController.setBindingFactory( bf );
selectedColumnController.setBindingFactory( bf );
constraintController.setBindingFactory( bf );
orderController.setBindingFactory( bf );
previewController.setBindingFactory( bf );
container.addEventHandler( mainController );
container.addEventHandler( selectedColumnController );
container.addEventHandler( constraintController );
container.addEventHandler( orderController );
container.addEventHandler( previewController );
mainController.setWorkspace( workspace );
selectedColumnController.setWorkspace( workspace );
constraintController.setWorkspace( workspace );
orderController.setWorkspace( workspace );
previewController.setWorkspace( workspace );
} catch ( XulException e ) {
log.error( "error loading Xul application", e );
}
}
开发者ID:pentaho,项目名称:mql-editor,代码行数:35,代码来源:AbstractMqlEditor.java
示例17: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
protected void addToolBar() {
try {
XulLoader loader = new KettleXulLoader();
loader.setSettingsManager( XulSpoonSettingsManager.getInstance() );
ResourceBundle bundle = GlobalMessages.getBundle( "org/pentaho/di/ui/spoon/messages/messages" );
XulDomContainer xulDomContainer = loader.loadXul( XUL_FILE_BROWSER_TOOLBAR, bundle );
xulDomContainer.addEventHandler( this );
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById( "nav-toolbar" );
@SuppressWarnings( "unused" )
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
spoon.props.setLook( swtToolBar, Props.WIDGET_STYLE_TOOLBAR );
// Add a URL
back = (XulToolbarbutton) toolbar.getElementById( "browse-back" );
back.setDisabled( true );
forward = (XulToolbarbutton) toolbar.getElementById( "browse-forward" );
forward.setLabel( BaseMessages.getString( PKG, "SpoonBrowser.Dialog.Forward" ) );
forward.setDisabled( false );
location = (XulTextbox) toolbar.getElementById( "browser-address" );
Control toolbarControl = (Control) toolbar.getManagedObject();
toolbarControl.setLayoutData( new FormData() );
toolbarControl.setParent( composite );
} catch ( Exception e ) {
e.printStackTrace();
new ErrorDialog(
shell, BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Title" ), BaseMessages
.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_BROWSER_TOOLBAR ), e );
}
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:33,代码来源:SpoonBrowser.java
示例18: addToolBar
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
private void addToolBar() {
try {
XulLoader loader = new KettleXulLoader();
loader.setSettingsManager( XulSpoonSettingsManager.getInstance() );
ResourceBundle bundle = GlobalMessages.getBundle( "org/pentaho/di/ui/spoon/messages/messages" );
XulDomContainer xulDomContainer = loader.loadXul( XUL_FILE_TRANS_PREVIEW_TOOLBAR, bundle );
xulDomContainer.addEventHandler( this );
toolbar = (XulToolbar) xulDomContainer.getDocumentRoot().getElementById( "nav-toolbar" );
ToolBar swtToolBar = (ToolBar) toolbar.getManagedObject();
spoon.props.setLook( swtToolBar, Props.WIDGET_STYLE_TOOLBAR );
swtToolBar.layout( true, true );
swtToolBar.pack();
firstRadio = (SwtRadio) xulDomContainer.getDocumentRoot().getElementById( "preview-first" );
lastRadio = (SwtRadio) xulDomContainer.getDocumentRoot().getElementById( "preview-last" );
offRadio = (SwtRadio) xulDomContainer.getDocumentRoot().getElementById( "preview-off" );
PropsUI.getInstance().setLook( (Control) firstRadio.getManagedObject(), Props.WIDGET_STYLE_TOOLBAR );
PropsUI.getInstance().setLook( (Control) lastRadio.getManagedObject(), Props.WIDGET_STYLE_TOOLBAR );
PropsUI.getInstance().setLook( (Control) offRadio.getManagedObject(), Props.WIDGET_STYLE_TOOLBAR );
} catch ( Throwable t ) {
log.logError( toString(), Const.getStackTracker( t ) );
new ErrorDialog( transPreviewComposite.getShell(),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Title" ),
BaseMessages.getString( PKG, "Spoon.Exception.ErrorReadingXULFile.Message", XUL_FILE_TRANS_PREVIEW_TOOLBAR ),
new Exception( t ) );
}
}
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:31,代码来源:TransPreviewDelegate.java
示例19: setXulLoader
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
public void setXulLoader(XulLoader xulLoader) {
this.xulLoader = xulLoader;
}
开发者ID:pentaho,项目名称:pentaho-aggdesigner,代码行数:4,代码来源:UIMain.java
示例20: getLoader
import org.pentaho.ui.xul.XulLoader; //导入依赖的package包/类
protected abstract XulLoader getLoader();
开发者ID:pentaho,项目名称:mql-editor,代码行数:2,代码来源:AbstractMqlEditor.java
注:本文中的org.pentaho.ui.xul.XulLoader类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论