FileDocCategorySizeDatePackage
ConfigSectionInterfaceStart.javaAPI DocAzureus 3.0.3.45200Fri Aug 31 16:24:22 BST 2007org.gudy.azureus2.ui.swt.views.configsections

ConfigSectionInterfaceStart

public class ConfigSectionInterfaceStart extends Object implements org.gudy.azureus2.ui.swt.plugins.UISWTConfigSection

Fields Summary
Constructors Summary
Methods Summary
public CompositeconfigSectionCreate(Composite parent)

    // "Start" Sub-Section
    // -------------------
    GridLayout layout;
    Composite cStart = new Composite(parent, SWT.NULL);

    cStart.setLayoutData(new GridData(GridData.FILL_BOTH));
    layout = new GridLayout();
    layout.numColumns = 1;
    cStart.setLayout(layout);

    new BooleanParameter(cStart, "Show Splash", "ConfigView.label.showsplash");
    new BooleanParameter(cStart, "update.start", "ConfigView.label.checkonstart");
    new BooleanParameter(cStart, "update.periodic", "ConfigView.label.periodiccheck");
    BooleanParameter autoDownload = new BooleanParameter(cStart, "update.autodownload", "ConfigView.section.update.autodownload");
    BooleanParameter openDialog = new BooleanParameter(cStart, "update.opendialog", "ConfigView.label.opendialog");
    
		autoDownload.setAdditionalActionPerformer(new ChangeSelectionActionPerformer(
				new Control[] { openDialog.getControl() }, true ));
    
    new Label(cStart,SWT.NULL);
    new BooleanParameter(cStart, "Open MyTorrents", "ConfigView.label.openmytorrents");
    new BooleanParameter(cStart, "Open Console", "ConfigView.label.openconsole");
    new BooleanParameter(cStart, "Open Stats On Start", "ConfigView.label.openstatsonstart");
    new BooleanParameter(cStart, "Open Config", "ConfigView.label.openconfig");
    new BooleanParameter(cStart, "Open Transfer Bar On Start", "ConfigView.label.open_transfer_bar_on_start");
    new BooleanParameter(cStart, "Start Minimized", "ConfigView.label.startminimized");
    
    if (COConfigurationManager.getStringParameter("ui").equals("az3")) {
			new BooleanParameter(cStart, "v3.Start Advanced",
					"ConfigView.interface.start.advanced");
		}
  
	// UI switcher window.
    Composite cUISwitcher = new Composite(cStart, SWT.NONE);
    layout = new GridLayout(2, false);
    layout.marginHeight = 0;
    layout.marginWidth = 0;
		cUISwitcher.setLayout(layout);

		final Label ui_switcher_label = new Label(cUISwitcher, SWT.NULL);
		Messages.setLanguageText(ui_switcher_label, "ConfigView.label.ui_switcher");

		final Button ui_switcher_button = new Button(cUISwitcher, SWT.PUSH);
		Messages.setLanguageText(ui_switcher_button,
				"ConfigView.label.ui_switcher_button");

		ui_switcher_button.addListener(SWT.Selection, new Listener() {
			public void handleEvent(Event event) {
				String uiOld = COConfigurationManager.getStringParameter("ui");
				String uiNew = UISwitcherUtil.openSwitcherWindow(true);
				if (!uiOld.equals(uiNew)) {
  				int result = MessageBoxShell.open(parent.getShell(),
  						MessageText.getString("dialog.uiswitcher.restart.title"),
  						MessageText.getString("dialog.uiswitcher.restart.text"),
  						new String[] {
  							MessageText.getString("UpdateWindow.restart"),
  							MessageText.getString("UpdateWindow.restartLater"),
  						}, 0);
  				if (result == 0) {
  					UIFunctions uif = UIFunctionsManager.getUIFunctions();
  					if (uif != null) {
  						uif.dispose(true, false);
  					}
  				}
				}
			}
		});
    
    return cStart;
  
public voidconfigSectionDelete()

  
public java.lang.StringconfigSectionGetName()

		return "start";
	
public java.lang.StringconfigSectionGetParentSection()

    return ConfigSection.SECTION_INTERFACE;
  
public voidconfigSectionSave()