bugged
stringlengths 6
599k
| fixed
stringlengths 6
40.8M
| __index_level_0__
int64 0
3.24M
|
---|---|---|
protected XMLStringBuffer createContentBuffer() { XMLStringBuffer suiteBuffer= new XMLStringBuffer(""); //$NON-NLS-1$ suiteBuffer.setDocType("suite SYSTEM \"" + Parser.TESTNG_DTD_URL + "\""); Properties attrs= new Properties(); attrs.setProperty("name", m_suiteName); suiteBuffer.push("suite", attrs); if(m_parameters != null) { for(Iterator it= m_parameters.entrySet().iterator(); it.hasNext(); ) { Map.Entry entry= (Map.Entry) it.next(); Properties paramAttrs= new Properties(); paramAttrs.setProperty("name", (String) entry.getKey()); paramAttrs.setProperty("value", (String) entry.getValue()); suiteBuffer.push("parameter", paramAttrs); suiteBuffer.pop("parameter"); } } initContentBuffer(suiteBuffer); suiteBuffer.pop("suite"); return suiteBuffer; }
|
protected XMLStringBuffer createContentBuffer() { XMLStringBuffer suiteBuffer= new XMLStringBuffer(""); //$NON-NLS-1$ suiteBuffer.setDocType("suite SYSTEM \"" + Parser.TESTNG_DTD_URL + "\""); Properties attrs= new Properties(); attrs.setProperty("name", m_suiteName); suiteBuffer.push("suite", attrs); if(m_parameters != null) { for(Iterator it= m_parameters.entrySet().iterator(); it.hasNext(); ) { Map.Entry entry= (Map.Entry) it.next(); Properties paramAttrs= new Properties(); paramAttrs.setProperty("name", (String) entry.getKey()); paramAttrs.setProperty("value", (String) entry.getValue()); suiteBuffer.push("parameter", paramAttrs); suiteBuffer.pop("parameter"); } } initContentBuffer(suiteBuffer); suiteBuffer.pop("suite"); return suiteBuffer; }
| 3,241,765 |
private XMLStringBuffer getSuiteBuffer() { if(null == m_suiteBuffer) { m_suiteBuffer= createContentBuffer(); } return m_suiteBuffer; }
|
private XMLStringBuffer getSuiteBuffer() { if(null == m_suiteBuffer) { m_suiteBuffer= createContentBuffer(); } return m_suiteBuffer; }
| 3,241,766 |
private XMLStringBuffer getSuiteBuffer() { if(null == m_suiteBuffer) { m_suiteBuffer= createContentBuffer(); } return m_suiteBuffer; }
|
private XMLStringBuffer getSuiteBuffer() { if(null == m_suiteBuffer) { m_suiteBuffer= createContentBuffer(); } return m_suiteBuffer; }
| 3,241,767 |
protected abstract void initContentBuffer(XMLStringBuffer suiteBuffer);
|
protected abstract void initContentBuffer(XMLStringBuffer suiteBuffer);
| 3,241,768 |
public File save(File directory) { final File suiteFile= new File(directory, "temp-testng-customsuite.xml"); saveSuiteContent(suiteFile, getSuiteBuffer()); return suiteFile; }
|
public File save(File directory) { final File suiteFile= new File(directory, "temp-testng-customsuite.xml"); saveSuiteContent(suiteFile, getSuiteBuffer()); return suiteFile; }
| 3,241,769 |
public File save(File directory) { final File suiteFile= new File(directory, "temp-testng-customsuite.xml"); saveSuiteContent(suiteFile, getSuiteBuffer()); return suiteFile; }
|
public File save(File directory) { final File suiteFile= new File(directory, "temp-testng-customsuite.xml"); saveSuiteContent(suiteFile, getSuiteBuffer()); return suiteFile; }
| 3,241,770 |
public File save(File directory) { final File suiteFile= new File(directory, "temp-testng-customsuite.xml"); saveSuiteContent(suiteFile, getSuiteBuffer()); return suiteFile; }
|
public File save(File directory) { final File suiteFile= new File(directory, "temp-testng-customsuite.xml"); saveSuiteContent(suiteFile, getSuiteBuffer()); return suiteFile; }
| 3,241,771 |
protected void saveSuiteContent(final File file, final XMLStringBuffer content) { FileWriter fw= null; BufferedWriter bw= null; try { fw= new FileWriter(file); bw= new BufferedWriter(fw); bw.write(content.getStringBuffer().toString()); bw.flush(); } catch(IOException ioe) { } finally { if(null != bw) { try { bw.close(); } catch(IOException ioe) { } } if(null != fw) { try { fw.close(); } catch(IOException ioe) { } } } }
|
protected void saveSuiteContent(final File file, final XMLStringBuffer content) { FileWriter fw= null; BufferedWriter bw= null; try { fw= new FileWriter(file); bw= new BufferedWriter(fw); bw.write(content.getStringBuffer().toString()); bw.flush(); } catch(IOException ioe) { } finally { if(null != bw) { try { bw.close(); } catch(IOException ioe) { } } if(null != fw) { try { fw.close(); } catch(IOException ioe) { } } } }
| 3,241,772 |
protected void saveSuiteContent(final File file, final XMLStringBuffer content) { FileWriter fw= null; BufferedWriter bw= null; try { fw= new FileWriter(file); bw= new BufferedWriter(fw); bw.write(content.getStringBuffer().toString()); bw.flush(); } catch(IOException ioe) { } finally { if(null != bw) { try { bw.close(); } catch(IOException ioe) { } } if(null != fw) { try { fw.close(); } catch(IOException ioe) { } } } }
|
protected void saveSuiteContent(final File file, final XMLStringBuffer content) { FileWriter fw= null; BufferedWriter bw= null; try { fw= new FileWriter(file); bw= new BufferedWriter(fw); bw.write(content.getStringBuffer().toString()); bw.flush(); } catch(IOException ioe) { } finally { if(null != bw) { try { bw.close(); } catch(IOException ioe) { } } if(null != fw) { try { fw.close(); } catch(IOException ioe) { } } } }
| 3,241,773 |
protected void saveSuiteContent(final File file, final XMLStringBuffer content) { FileWriter fw= null; BufferedWriter bw= null; try { fw= new FileWriter(file); bw= new BufferedWriter(fw); bw.write(content.getStringBuffer().toString()); bw.flush(); } catch(IOException ioe) { } finally { if(null != bw) { try { bw.close(); } catch(IOException ioe) { } } if(null != fw) { try { fw.close(); } catch(IOException ioe) { } } } }
|
protected void saveSuiteContent(final File file, final XMLStringBuffer content) { FileWriter fw= null; BufferedWriter bw= null; try { fw= new FileWriter(file); bw= new BufferedWriter(fw); bw.write(content.getStringBuffer().toString()); bw.flush(); } catch(IOException ioe) { } finally { if(null != bw) { try { bw.close(); } catch(IOException ioe) { } } if(null != fw) { try { fw.close(); } catch(IOException ioe) { } } } }
| 3,241,774 |
public void performApply(ILaunchConfigurationWorkingCopy configuration) { ConfigurationHelper.updateLaunchConfiguration(configuration, new ConfigurationHelper.LaunchInfo(m_projectText.getText(), m_typeOfTestRun, m_classText.getText(), m_groupMap, m_suiteText.getText(), m_complianceLevelCombo.getText(), m_logLevelCombo.getText())); }
|
public void performApply(ILaunchConfigurationWorkingCopy configuration) { ConfigurationHelper.updateLaunchConfiguration(configuration, new ConfigurationHelper.LaunchInfo(m_projectText.getText(), m_typeOfTestRun, Utils.stringToList(m_classText.getText().trim()), m_groupMap, m_suiteText.getText(), m_complianceLevelCombo.getText(), m_logLevelCombo.getText())); }
| 3,241,776 |
public ShortcutPanel(InstallerFrame parent, InstallData installData) { super(parent, installData, "link16x16"); try { readShortcutSpec(); } catch (Throwable exception) { System.out.println("could not read shortcut spec!"); exception.printStackTrace(); } layout = new GridBagLayout(); constraints = new GridBagConstraints(); setLayout(layout); // Create the UI elements try { shortcut = (Shortcut) (TargetFactory.getInstance() .makeObject("com.izforge.izpack.util.os.Shortcut")); shortcut.initialize(Shortcut.APPLICATIONS, "-"); } catch (Throwable exception) { System.out.println("could not create shortcut instance"); exception.printStackTrace(); } }
|
public ShortcutPanel(InstallerFrame parent, InstallData installData) { super(parent, installData, "link16x16"); try { readShortcutSpec(); } catch (Throwable exception) { System.out.println("could not read shortcut spec!"); exception.printStackTrace(); } layout = new GridBagLayout(); constraints = new GridBagConstraints(); setLayout(layout); // Create the UI elements try { shortcut = (Shortcut) (TargetFactory.getInstance() .makeObject("com.izforge.izpack.util.os.Shortcut")); shortcut.initialize(Shortcut.APPLICATIONS, "-"); } catch (Throwable exception) { System.out.println("could not create shortcut instance"); exception.printStackTrace(); } }
| 3,241,778 |
public ShortcutPanel(InstallerFrame parent, InstallData installData) { super(parent, installData, "link16x16"); try { readShortcutSpec(); } catch (Throwable exception) { System.out.println("could not read shortcut spec!"); exception.printStackTrace(); } layout = new GridBagLayout(); constraints = new GridBagConstraints(); setLayout(layout); // Create the UI elements try { shortcut = (Shortcut) (TargetFactory.getInstance() .makeObject("com.izforge.izpack.util.os.Shortcut")); shortcut.initialize(Shortcut.APPLICATIONS, "-"); } catch (Throwable exception) { System.out.println("could not create shortcut instance"); exception.printStackTrace(); } }
|
public ShortcutPanel(InstallerFrame parent, InstallData installData) { super(parent, installData, "link16x16"); try { readShortcutSpec(); } catch (Throwable exception) { System.out.println("could not read shortcut spec!"); exception.printStackTrace(); } layout = new GridBagLayout(); constraints = new GridBagConstraints(); setLayout(layout); // Create the UI elements try { shortcut = (Shortcut) (TargetFactory.getInstance() .makeObject("com.izforge.izpack.util.os.Shortcut")); shortcut.initialize(Shortcut.APPLICATIONS, "-"); } catch (Throwable exception) { System.out.println("could not create shortcut instance"); exception.printStackTrace(); } }
| 3,241,779 |
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
|
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
| 3,241,780 |
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
|
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
| 3,241,781 |
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
|
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); if (groupList != null) { groupList.setEnabled(create); } programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
| 3,241,782 |
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
|
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
| 3,241,783 |
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
|
public void actionPerformed(ActionEvent event) { Object eventSource = event.getSource(); // ---------------------------------------------------- // create shortcut for the current user was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- if (eventSource.equals(currentUser)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.CURRENT_USER)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.CURRENT_USER); } // ---------------------------------------------------- // create shortcut for all users was selected // refresh the list of program groups accordingly and // reset the program group to the default setting. // ---------------------------------------------------- else if (eventSource.equals(allUsers)) { groupList.setListData(shortcut.getProgramGroups(Shortcut.ALL_USERS)); programGroup.setText(suggestedProgramGroup); shortcut.setUserType(itsUserType = Shortcut.ALL_USERS); } // ---------------------------------------------------- // The reset button was pressed. // - clear the selection in the list box, because the // selection is no longer valid // - refill the program group edit control with the // suggested program group name // ---------------------------------------------------- else if (eventSource.equals(defaultButton)) { groupList.getSelectionModel().clearSelection(); programGroup.setText(suggestedProgramGroup); } // ---------------------------------------------------- // the save button was pressed. This is a request to // save shortcut information to a text file. // ---------------------------------------------------- else if (eventSource.equals(saveButton)) { saveToFile(); // add the file to the uninstaller addToUninstaller(); } else if (eventSource.equals(createShortcuts)) { create = createShortcuts.isSelected(); groupList.setEnabled(create); programGroup.setEnabled(create); currentUser.setEnabled(create); defaultButton.setEnabled(create); allowDesktopShortcut.setEnabled(create); if( isRootUser ) allUsers.setEnabled(create); } }
| 3,241,784 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,786 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,787 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) { continue; } if (!checkConditions(shortcutSpec)) { continue; } data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,788 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP, ""); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,789 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,790 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,791 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,792 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,793 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,794 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,795 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,796 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (XMLHelper.attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,797 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (XMLHelper.attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,798 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (XMLHelper.attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,799 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (XMLHelper.attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,800 |
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
|
private void analyzeShortcutSpec() { if (!haveShortcutSpec) { shortcutsToCreate = false; return; } XMLElement skipper = spec.getFirstChildNamed(SPEC_KEY_SKIP_IFNOT_SUPPORTED); skipIfNotSupported = (skipper != null); // ---------------------------------------------------- // find out if we should simulate a not supported // scenario // ---------------------------------------------------- XMLElement support = spec.getFirstChildNamed(SPEC_KEY_NOT_SUPPORTED); if (support != null) { simulteNotSupported = true; } // ---------------------------------------------------- // find out in which program group the shortcuts should // be placed and where this program group should be // located // ---------------------------------------------------- XMLElement group = spec.getFirstChildNamed(SPEC_KEY_PROGRAM_GROUP); String location = null; hasDesktopShortcuts = false; if (group != null) { suggestedProgramGroup = group.getAttribute(SPEC_ATTRIBUTE_DEFAULT_GROUP, ""); location = group.getAttribute(SPEC_ATTRIBUTE_LOCATION, SPEC_VALUE_APPLICATIONS); } else { suggestedProgramGroup = ""; location = SPEC_VALUE_APPLICATIONS; } int groupLocation; if (location.equals(SPEC_VALUE_APPLICATIONS)) { groupLocation = Shortcut.APPLICATIONS; } else if (location.equals(SPEC_VALUE_START_MENU)) { groupLocation = Shortcut.START_MENU; } // ---------------------------------------------------- // create a list of all shortcuts that need to be // created, containing all details about each shortcut // ---------------------------------------------------- VariableSubstitutor substitutor = new VariableSubstitutor(idata.getVariables()); String temp; Vector shortcutSpecs = spec.getChildrenNamed(SPEC_KEY_SHORTCUT); XMLElement shortcutSpec; ShortcutData data; for (int i = 0; i < shortcutSpecs.size(); i++) { shortcutSpec = (XMLElement) shortcutSpecs.elementAt(i); if (!OsConstraint.oneMatchesCurrentSystem(shortcutSpec)) continue; data = new ShortcutData(); data.name = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_NAME); data.subgroup = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_SUBGROUP); data.description = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_DESCRIPTION, ""); //** Linux **// data.deskTopEntryLinux_Encoding = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_ENCODING, ""); data.deskTopEntryLinux_MimeType = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_MIMETYPE, ""); data.deskTopEntryLinux_Terminal = shortcutSpec .getAttribute(SPEC_ATTRIBUTE_TERMINAL, ""); data.deskTopEntryLinux_TerminalOptions = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_TERMINAL_OPTIONS, ""); data.deskTopEntryLinux_Type = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TYPE, ""); data.deskTopEntryLinux_URL = substitutor.substitute(shortcutSpec.getAttribute( SPEC_ATTRIBUTE_URL, ""), null); data.deskTopEntryLinux_X_KDE_SubstituteUID = shortcutSpec.getAttribute( SPEC_ATTRIBUTE_KDE_SUBST_UID, ""); data.createForAll = Boolean.valueOf(shortcutSpec.getAttribute(CREATE_FOR_ALL, "false")); //** EndOf LINUX **// temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_TARGET, "")); data.target = substitutor.substitute(temp, null); temp = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_COMMAND, ""); data.commandLine = substitutor.substitute(temp, null); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON, "")); data.iconFile = substitutor.substitute(temp, null); data.iconIndex = Integer.parseInt(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_ICON_INDEX, "0")); temp = fixSeparatorChar(shortcutSpec.getAttribute(SPEC_ATTRIBUTE_WORKING_DIR, "")); data.workingDirectory = substitutor.substitute(temp, null); String initialState = shortcutSpec.getAttribute(SPEC_ATTRIBUTE_INITIAL_STATE, ""); if (initialState.equals(SPEC_VALUE_NO_SHOW)) { data.initialState = Shortcut.HIDE; } else if (initialState.equals(SPEC_VALUE_NORMAL)) { data.initialState = Shortcut.NORMAL; } else if (initialState.equals(SPEC_VALUE_MAXIMIZED)) { data.initialState = Shortcut.MAXIMIZED; } else if (initialState.equals(SPEC_VALUE_MINIMIZED)) { data.initialState = Shortcut.MINIMIZED; } else { data.initialState = Shortcut.NORMAL; } // -------------------------------------------------- // if the minimal data requirements are met to create // the shortcut, create one entry each for each of // the requested types. // Eventually this will cause the creation of one // shortcut in each of the associated locations. // -------------------------------------------------- // without a name we can not create a shortcut if (data.name == null) { continue; } //1. Elmar: "Without a target we can not create a shortcut." //2. Marc: "No, Even on Linux a Link can be an URL and has no target." if (data.target == null) { continue; } // the shortcut is not actually required for any of the selected packs Vector forPacks = shortcutSpec.getChildrenNamed(SPEC_KEY_PACKS); if (!shortcutRequiredFor(forPacks)) { continue; } // -------------------------------------------------- // This section is executed if we don't skip. // -------------------------------------------------- // For each of the categories set the type and if // the link should be placed in the program group, // then clone the data set to obtain an independent // instance and add this to the list of shortcuts // to be created. In this way, we will set up an // identical copy for each of the locations at which // a shortcut should be placed. Therefore you must // not use 'else if' statements! // -------------------------------------------------- { if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_DESKTOP)) { hasDesktopShortcuts = true; data.addToGroup = false; data.type = Shortcut.DESKTOP; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_APPLICATIONS)) { data.addToGroup = false; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_START_MENU)) { data.addToGroup = false; data.type = Shortcut.START_MENU; shortcuts.add(data.clone()); } if (attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_STARTUP)) { data.addToGroup = false; data.type = Shortcut.START_UP; shortcuts.add(data.clone()); } if (XMLHelper.attributeIsTrue(shortcutSpec, SPEC_ATTRIBUTE_PROGRAM_GROUP)) { data.addToGroup = true; data.type = Shortcut.APPLICATIONS; shortcuts.add(data.clone()); } } } // ---------------------------------------------------- // signal if there are any shortcuts to create // ---------------------------------------------------- if (shortcuts.size() > 0) { shortcutsToCreate = true; } }
| 3,241,801 |
private void buildAlternateUI() { layout = new GridBagLayout(); constraints = new GridBagConstraints(); setLayout(layout); // ---------------------------------------------------- // static text a the top of the panel, that apologizes // about the fact that we can not create shortcuts on // this particular target OS. // ---------------------------------------------------- MultiLineLabel apologyLabel = new MultiLineLabel(parent.langpack .getString("ShortcutPanel.alternate.apology"), 0, 0); constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.insets = new Insets(5, 5, 5, 5); constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(apologyLabel, constraints); add(apologyLabel); // ---------------------------------------------------- // label that explains the significance ot the list box // ---------------------------------------------------- MultiLineLabel listLabel = new MultiLineLabel(parent.langpack .getString("ShortcutPanel.alternate.targetsLabel"), 0, 0); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of the intended shortcut targets // ---------------------------------------------------- Vector targets = new Vector(); for (int i = 0; i < shortcuts.size(); i++) { targets.add(((ShortcutData) shortcuts.elementAt(i)).target); } JList targetList = new JList(targets); JScrollPane scrollPane = new JScrollPane(targetList); constraints.gridx = 0; constraints.gridy = 2; constraints.fill = GridBagConstraints.BOTH; layout.addLayoutComponent(scrollPane, constraints); add(scrollPane); // ---------------------------------------------------- // static text that explains about the text file // ---------------------------------------------------- MultiLineLabel fileExplanation = new MultiLineLabel(parent.langpack .getString("ShortcutPanel.alternate.textFileExplanation"), 0, 0); constraints.gridx = 0; constraints.gridy = 3; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(fileExplanation, constraints); add(fileExplanation); // ---------------------------------------------------- // button to save the text file // ---------------------------------------------------- saveButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.alternate.saveButton"), idata.buttonsHColor); saveButton.addActionListener(this); constraints.gridx = 0; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.CENTER; layout.addLayoutComponent(saveButton, constraints); add(saveButton); }
|
private void buildAlternateUI() { layout = new GridBagLayout(); constraints = new GridBagConstraints(); setLayout(layout); // ---------------------------------------------------- // static text a the top of the panel, that apologizes // about the fact that we can not create shortcuts on // this particular target OS. // ---------------------------------------------------- MultiLineLabel apologyLabel = new MultiLineLabel(parent.langpack .getString("ShortcutPanel.alternate.apology"), 0, 0); constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.insets = new Insets(5, 5, 5, 5); constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(apologyLabel, constraints); add(apologyLabel); // ---------------------------------------------------- // label that explains the significance ot the list box // ---------------------------------------------------- MultiLineLabel listLabel = new MultiLineLabel(parent.langpack .getString("ShortcutPanel.alternate.targetsLabel"), 0, 0); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of the intended shortcut targets // ---------------------------------------------------- Vector targets = new Vector(); for (int i = 0; i < shortcuts.size(); i++) { targets.add(((ShortcutData) shortcuts.elementAt(i)).target); } targetList = new JList(targets); JScrollPane scrollPane = new JScrollPane(targetList); constraints.gridx = 0; constraints.gridy = 2; constraints.fill = GridBagConstraints.BOTH; layout.addLayoutComponent(scrollPane, constraints); add(scrollPane); // ---------------------------------------------------- // static text that explains about the text file // ---------------------------------------------------- MultiLineLabel fileExplanation = new MultiLineLabel(parent.langpack .getString("ShortcutPanel.alternate.textFileExplanation"), 0, 0); constraints.gridx = 0; constraints.gridy = 3; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(fileExplanation, constraints); add(fileExplanation); // ---------------------------------------------------- // button to save the text file // ---------------------------------------------------- saveButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.alternate.saveButton"), idata.buttonsHColor); saveButton.addActionListener(this); constraints.gridx = 0; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.CENTER; layout.addLayoutComponent(saveButton, constraints); add(saveButton); }
| 3,241,803 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,804 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,805 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,806 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,807 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); private constraints.insets = new Insets(0, 10, 0, 0); void constraints.insets = new Insets(0, 10, 0, 0); buildUI(File constraints.insets = new Insets(0, 10, 0, 0); groups) constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); { constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); File constraints.insets = new Insets(0, 10, 0, 0); itsProgramFolder constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); groups; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridy constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridwidth constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 3; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridheight constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weightx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1.0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weighty constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1.0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.fill constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.HORIZONTAL; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.anchor constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.WEST; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); /**/ constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); Add constraints.insets = new Insets(0, 10, 0, 0); a constraints.insets = new Insets(0, 10, 0, 0); CheckBox constraints.insets = new Insets(0, 10, 0, 0); which constraints.insets = new Insets(0, 10, 0, 0); enables constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); user constraints.insets = new Insets(0, 10, 0, 0); to constraints.insets = new Insets(0, 10, 0, 0); entirely constraints.insets = new Insets(0, 10, 0, 0); supress constraints.insets = new Insets(0, 10, 0, 0); shortcut constraints.insets = new Insets(0, 10, 0, 0); creation. constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); String constraints.insets = new Insets(0, 10, 0, 0); menuKind constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); if( constraints.insets = new Insets(0, 10, 0, 0); OsVersion.IS_UNIX constraints.insets = new Insets(0, 10, 0, 0); && constraints.insets = new Insets(0, 10, 0, 0); UnixHelper.kdeIsInstalled() constraints.insets = new Insets(0, 10, 0, 0); ) constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); menuKind constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); createShortcuts constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); JCheckBox( constraints.insets = new Insets(0, 10, 0, 0); StringTool.replace( constraints.insets = new Insets(0, 10, 0, 0); parent.langpack.getString("ShortcutPanel.regular.create"), constraints.insets = new Insets(0, 10, 0, 0); "StartMenu", constraints.insets = new Insets(0, 10, 0, 0); menuKind constraints.insets = new Insets(0, 10, 0, 0); ), constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); true); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); createShortcuts.addActionListener(this); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridy constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridwidth constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridheight constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weighty constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0.2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); layout.addLayoutComponent(createShortcuts, constraints.insets = new Insets(0, 10, 0, 0); constraints); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); add(createShortcuts); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); check constraints.insets = new Insets(0, 10, 0, 0); box constraints.insets = new Insets(0, 10, 0, 0); to constraints.insets = new Insets(0, 10, 0, 0); allow constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); user constraints.insets = new Insets(0, 10, 0, 0); to constraints.insets = new Insets(0, 10, 0, 0); decide constraints.insets = new Insets(0, 10, 0, 0); if constraints.insets = new Insets(0, 10, 0, 0); a constraints.insets = new Insets(0, 10, 0, 0); desktop constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); shortcut constraints.insets = new Insets(0, 10, 0, 0); should constraints.insets = new Insets(0, 10, 0, 0); be constraints.insets = new Insets(0, 10, 0, 0); created. constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); this constraints.insets = new Insets(0, 10, 0, 0); should constraints.insets = new Insets(0, 10, 0, 0); only constraints.insets = new Insets(0, 10, 0, 0); be constraints.insets = new Insets(0, 10, 0, 0); created constraints.insets = new Insets(0, 10, 0, 0); if constraints.insets = new Insets(0, 10, 0, 0); needed constraints.insets = new Insets(0, 10, 0, 0); and constraints.insets = new Insets(0, 10, 0, 0); requested constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); in constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); definition constraints.insets = new Insets(0, 10, 0, 0); file. constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); if constraints.insets = new Insets(0, 10, 0, 0); (hasDesktopShortcuts) constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); { constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); String constraints.insets = new Insets(0, 10, 0, 0); initialAllowedValue constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); idata.getVariable( constraints.insets = new Insets(0, 10, 0, 0); "DesktopShortcutCheckboxEnabled" constraints.insets = new Insets(0, 10, 0, 0); ); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); boolean constraints.insets = new Insets(0, 10, 0, 0); initialAllowedFlag constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); false; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); if( constraints.insets = new Insets(0, 10, 0, 0); initialAllowedValue==null) constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); initialAllowedFlag= constraints.insets = new Insets(0, 10, 0, 0); false; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); else constraints.insets = new Insets(0, 10, 0, 0); if( constraints.insets = new Insets(0, 10, 0, 0); Boolean.TRUE.toString().equals(initialAllowedValue) constraints.insets = new Insets(0, 10, 0, 0); ) constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); initialAllowedFlag=true; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); allowDesktopShortcut constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); JCheckBox(parent.langpack constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); .getString("ShortcutPanel.regular.desktop"), constraints.insets = new Insets(0, 10, 0, 0); initialAllowedFlag); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridy constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridwidth constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 3; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridheight constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weighty constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0.2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); layout.addLayoutComponent(allowDesktopShortcut, constraints.insets = new Insets(0, 10, 0, 0); constraints); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); add(allowDesktopShortcut); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); } constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); JLabel constraints.insets = new Insets(0, 10, 0, 0); listLabel constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); JLabel.LEADING); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridy constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 3; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridwidth constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridheight constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weightx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0.2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weighty constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0.2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.fill constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.NONE; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.anchor constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.WEST; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); layout.addLayoutComponent(listLabel, constraints.insets = new Insets(0, 10, 0, 0); constraints); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); add(listLabel); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); list constraints.insets = new Insets(0, 10, 0, 0); box constraints.insets = new Insets(0, 10, 0, 0); to constraints.insets = new Insets(0, 10, 0, 0); list constraints.insets = new Insets(0, 10, 0, 0); all constraints.insets = new Insets(0, 10, 0, 0); of constraints.insets = new Insets(0, 10, 0, 0); already constraints.insets = new Insets(0, 10, 0, 0); existing constraints.insets = new Insets(0, 10, 0, 0); folders constraints.insets = new Insets(0, 10, 0, 0); as constraints.insets = new Insets(0, 10, 0, 0); program constraints.insets = new Insets(0, 10, 0, 0); groups constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); at constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); intended constraints.insets = new Insets(0, 10, 0, 0); destination constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); addSelectionList( constraints.insets = new Insets(0, 10, 0, 0); groups, constraints.insets = new Insets(0, 10, 0, 0); 0, constraints.insets = new Insets(0, 10, 0, 0); 4, constraints.insets = new Insets(0, 10, 0, 0); 2, constraints.insets = new Insets(0, 10, 0, 0); 1, constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.BOTH constraints.insets = new Insets(0, 10, 0, 0); ); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); radio constraints.insets = new Insets(0, 10, 0, 0); buttons constraints.insets = new Insets(0, 10, 0, 0); to constraints.insets = new Insets(0, 10, 0, 0); select constraints.insets = new Insets(0, 10, 0, 0); current constraints.insets = new Insets(0, 10, 0, 0); user constraints.insets = new Insets(0, 10, 0, 0); or constraints.insets = new Insets(0, 10, 0, 0); all constraints.insets = new Insets(0, 10, 0, 0); users. constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); if constraints.insets = new Insets(0, 10, 0, 0); (shortcut.multipleUsers()) constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); { constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); JPanel constraints.insets = new Insets(0, 10, 0, 0); usersPanel constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); JPanel(new constraints.insets = new Insets(0, 10, 0, 0); GridLayout(2, constraints.insets = new Insets(0, 10, 0, 0); 1)); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); ButtonGroup constraints.insets = new Insets(0, 10, 0, 0); usersGroup constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); ButtonGroup(); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); currentUser constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); JRadioButton(parent.langpack constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); .getString("ShortcutPanel.regular.currentUser"), constraints.insets = new Insets(0, 10, 0, 0); !isRootUser); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); currentUser.addActionListener(this); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); usersGroup.add(currentUser); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); usersPanel.add(currentUser); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); allUsers constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); JRadioButton( constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); parent.langpack.getString("ShortcutPanel.regular.allUsers"), constraints.insets = new Insets(0, 10, 0, 0); isRootUser); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); if constraints.insets = new Insets(0, 10, 0, 0); (!isRootUser) constraints.insets = new Insets(0, 10, 0, 0); allUsers.setEnabled(false); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); allUsers.addActionListener(this); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); usersGroup.add(allUsers); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); usersPanel.add(allUsers); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); TitledBorder constraints.insets = new Insets(0, 10, 0, 0); border constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); TitledBorder(new constraints.insets = new Insets(0, 10, 0, 0); EmptyBorder(2, constraints.insets = new Insets(0, 10, 0, 0); 2, constraints.insets = new Insets(0, 10, 0, 0); 2, constraints.insets = new Insets(0, 10, 0, 0); 2), constraints.insets = new Insets(0, 10, 0, 0); parent.langpack constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); .getString("ShortcutPanel.regular.userIntro")); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); usersPanel.setBorder(border); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridy constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 4; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridwidth constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridheight constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weighty constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1.0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weightx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1.0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.fill constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.NONE; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); layout.addLayoutComponent(usersPanel, constraints.insets = new Insets(0, 10, 0, 0); constraints); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); add(usersPanel); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); } constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); edit constraints.insets = new Insets(0, 10, 0, 0); box constraints.insets = new Insets(0, 10, 0, 0); that constraints.insets = new Insets(0, 10, 0, 0); contains constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); suggested constraints.insets = new Insets(0, 10, 0, 0); program constraints.insets = new Insets(0, 10, 0, 0); group constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); name, constraints.insets = new Insets(0, 10, 0, 0); which constraints.insets = new Insets(0, 10, 0, 0); can constraints.insets = new Insets(0, 10, 0, 0); be constraints.insets = new Insets(0, 10, 0, 0); modfied constraints.insets = new Insets(0, 10, 0, 0); or constraints.insets = new Insets(0, 10, 0, 0); substituted constraints.insets = new Insets(0, 10, 0, 0); from constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); list constraints.insets = new Insets(0, 10, 0, 0); by constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); user constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); programGroup constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); new constraints.insets = new Insets(0, 10, 0, 0); JTextField(suggestedProgramGroup, constraints.insets = new Insets(0, 10, 0, 0); 40); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); 40? constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridy constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 5; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridwidth constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridheight constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weighty constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1.0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.weightx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 10.0; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.fill constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.HORIZONTAL; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); layout.addLayoutComponent(programGroup, constraints.insets = new Insets(0, 10, 0, 0); constraints); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); add(programGroup); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); reset constraints.insets = new Insets(0, 10, 0, 0); button constraints.insets = new Insets(0, 10, 0, 0); that constraints.insets = new Insets(0, 10, 0, 0); allows constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); user constraints.insets = new Insets(0, 10, 0, 0); to constraints.insets = new Insets(0, 10, 0, 0); revert constraints.insets = new Insets(0, 10, 0, 0); to constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); original constraints.insets = new Insets(0, 10, 0, 0); suggestion constraints.insets = new Insets(0, 10, 0, 0); for constraints.insets = new Insets(0, 10, 0, 0); the constraints.insets = new Insets(0, 10, 0, 0); program constraints.insets = new Insets(0, 10, 0, 0); group constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); // constraints.insets = new Insets(0, 10, 0, 0); ---------------------------------------------------- constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); defaultButton constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); ButtonFactory.createButton(parent.langpack constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); .getString("ShortcutPanel.regular.default"), constraints.insets = new Insets(0, 10, 0, 0); idata.buttonsHColor); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); defaultButton.addActionListener(this); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridx constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 2; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridy constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 5; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridwidth constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.gridheight constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); 1; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.fill constraints.insets = new Insets(0, 10, 0, 0); = constraints.insets = new Insets(0, 10, 0, 0); GridBagConstraints.NONE; constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); layout.addLayoutComponent(defaultButton, constraints.insets = new Insets(0, 10, 0, 0); constraints); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); add(defaultButton); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); constraints.insets = new Insets(0, 10, 0, 0); }
| 3,241,808 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,809 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,810 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,811 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,812 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- Vector dirEntries = new Vector(); File[] entries = groups.listFiles(); if (entries != null) { for (int idx = 0; idx < entries.length; idx++) { if (entries[idx].isDirectory()) { dirEntries.add(entries[idx].getName()); } } } if (groupList == null) { groupList = new JList(); } groupList = addList(dirEntries, ListSelectionModel.SINGLE_SELECTION, groupList, col, line + 4, 1, 1, GridBagConstraints.BOTH); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,813 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) { allUsers.setEnabled(false); } allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,814 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,815 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,816 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,817 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,818 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,819 |
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
|
private void buildUI(File groups) { File itsProgramFolder = groups; constraints.gridx = 0; constraints.gridy = 0; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weightx = 1.0; constraints.weighty = 1.0; constraints.fill = GridBagConstraints.HORIZONTAL; constraints.anchor = GridBagConstraints.WEST; /**/ // Add a CheckBox which enables the user to entirely supress shortcut creation. String menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:Start-Menu"); if( OsVersion.IS_UNIX && UnixHelper.kdeIsInstalled() ) menuKind = parent.langpack.getString("ShortcutPanel.regular.StartMenu:K-Menu"); createShortcuts = new JCheckBox( StringTool.replace( parent.langpack.getString("ShortcutPanel.regular.create"), "StartMenu", menuKind ), true); createShortcuts.addActionListener(this); constraints.gridx = 0; constraints.gridy = 1; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(createShortcuts, constraints); add(createShortcuts); // ---------------------------------------------------- // check box to allow the user to decide if a desktop // shortcut should be created. // this should only be created if needed and requested // in the definition file. // ---------------------------------------------------- if (hasDesktopShortcuts) { String initialAllowedValue = idata.getVariable( "DesktopShortcutCheckboxEnabled" ); boolean initialAllowedFlag = false; if( initialAllowedValue==null) initialAllowedFlag= false; else if( Boolean.TRUE.toString().equals(initialAllowedValue) ) initialAllowedFlag=true; allowDesktopShortcut = new JCheckBox(parent.langpack .getString("ShortcutPanel.regular.desktop"), initialAllowedFlag); constraints.gridx = 0; constraints.gridy = 2; constraints.gridwidth = 3; constraints.gridheight = 1; constraints.weighty = 0.2; layout.addLayoutComponent(allowDesktopShortcut, constraints); add(allowDesktopShortcut); } JLabel listLabel = LabelFactory.create(parent.langpack.getString("ShortcutPanel.regular.list"), JLabel.LEADING); constraints.gridx = 0; constraints.gridy = 3; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weightx = 0.2; constraints.weighty = 0.2; constraints.fill = GridBagConstraints.NONE; constraints.anchor = GridBagConstraints.WEST; layout.addLayoutComponent(listLabel, constraints); add(listLabel); // ---------------------------------------------------- // list box to list all of already existing folders as program groups // at the intended destination // ---------------------------------------------------- addSelectionList( groups, 0, 4, 2, 1, GridBagConstraints.BOTH ); // ---------------------------------------------------- // radio buttons to select current user or all users. // ---------------------------------------------------- if (shortcut.multipleUsers()) { JPanel usersPanel = new JPanel(new GridLayout(2, 1)); ButtonGroup usersGroup = new ButtonGroup(); currentUser = new JRadioButton(parent.langpack .getString("ShortcutPanel.regular.currentUser"), !isRootUser); currentUser.addActionListener(this); usersGroup.add(currentUser); usersPanel.add(currentUser); allUsers = new JRadioButton( parent.langpack.getString("ShortcutPanel.regular.allUsers"), isRootUser); if (!isRootUser) allUsers.setEnabled(false); allUsers.addActionListener(this); usersGroup.add(allUsers); usersPanel.add(allUsers); TitledBorder border = new TitledBorder(new EmptyBorder(2, 2, 2, 2), parent.langpack .getString("ShortcutPanel.regular.userIntro")); usersPanel.setBorder(border); constraints.gridx = 2; constraints.gridy = 4; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 1.0; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(usersPanel, constraints); add(usersPanel); } // ---------------------------------------------------- // edit box that contains the suggested program group // name, which can be modfied or substituted from the // list by the user // ---------------------------------------------------- programGroup = new JTextField(suggestedProgramGroup, 40); // 40? constraints.gridx = 0; constraints.gridy = 5; constraints.gridwidth = 2; constraints.gridheight = 1; constraints.weighty = 1.0; constraints.weightx = 10.0; constraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(programGroup, constraints); add(programGroup); // ---------------------------------------------------- // reset button that allows the user to revert to the // original suggestion for the program group // ---------------------------------------------------- defaultButton = ButtonFactory.createButton(parent.langpack .getString("ShortcutPanel.regular.default"), idata.buttonsHColor); defaultButton.addActionListener(this); constraints.gridx = 2; constraints.gridy = 5; constraints.gridwidth = 1; constraints.gridheight = 1; constraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(defaultButton, constraints); add(defaultButton); }
| 3,241,820 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) { return; } ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,821 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,822 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,823 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(groupName); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,824 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,825 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) { break; } intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,826 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,827 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,828 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
privatevoidcreateShortcuts(){if(!create)return;ShortcutDatadata;Stringtmpgn;for(inti=0;i<shortcuts.size();i++){data=(ShortcutData)shortcuts.elementAt(i);try{//Thecloningguaranteesthatdata.subgroupwillnotbenull.//SeeShortcutData.cloneStringif(data.subgroup.length()>0&&(data.subgroup.charAt(0)=='/'||data.subgroup.charAt(0)=='\\')){tmpgn=groupName+data.subgroup;}else{tmpgn=groupName+File.separator+data.subgroup;}shortcut.setUserType(itsUserType);shortcut.setLinkName(data.name);shortcut.setLinkType(data.type);shortcut.setArguments(data.commandLine);shortcut.setDescription(data.description);shortcut.setIconLocation(data.iconFile,data.iconIndex);shortcut.setShowCommand(data.initialState);shortcut.setTargetPath(data.target);shortcut.setWorkingDirectory(data.workingDirectory);shortcut.setEncoding(data.deskTopEntryLinux_Encoding);shortcut.setMimetype(data.deskTopEntryLinux_MimeType);shortcut.setTerminal(data.deskTopEntryLinux_Terminal);shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions);shortcut.setType(data.deskTopEntryLinux_Type);shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID);shortcut.setURL(data.deskTopEntryLinux_URL);shortcut.setCreateForAll(data.createForAll);if(data.addToGroup){shortcut.setProgramGroup(tmpgn);}else{shortcut.setProgramGroup("");}try{//----------------------------------------------//savetheshortcutonlyifitiseithernoton//thedesktoporifitisonthedesktopand//theuserhassignalledthatitisoktoplace//shortcutsonthedesktop.//----------------------------------------------if((data.type!=Shortcut.DESKTOP)||((data.type==Shortcut.DESKTOP)&&allowDesktopShortcut.isSelected())){//savetheshortcutshortcut.save();//addthefileanddirectorynametothefilelistStringfileName=shortcut.getFileName();files.add(0,fileName);Filefile=newFile(fileName);Filebase=newFile(shortcut.getBasePath());Vectorintermediates=newVector();//StringdirectoryName=shortcut.getDirectoryCreated();execFiles.add(newExecutableFile(fileName,2,ExecutableFile.WARN,newArrayList(),false));files.add(fileName);while((file=file.getParentFile())!=null){if(file.equals(base))break;intermediates.add(file);}if(file!=null){for(Iteratoriter=intermediates.iterator();iter.hasNext();)files.add(0,iter.next().toString());}}}catch(Exceptionexception){}}catch(Throwableexception){}}//try{if(execFiles!=null){FileExecutorexecutor=newFileExecutor(execFiles);////TODO:HiGuys,//TODOThefollowingcommented-outlinesometimesproducesanuncatchable//nullpointerException!//TODOevaluateforwhatreasonthefilesshouldexec.//TODOifthereisaseriousexplanation,whytodothat,//TODOthecodemustbemorerobust//evaluateexecutor.executeFiles(ExecutableFile.NEVER,null);}}catch(NullPointerExceptionnep){nep.printStackTrace();}catch(RuntimeExceptioncannot){cannot.printStackTrace();}parent.unlockNextButton();}
| 3,241,829 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
| 3,241,830 |
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } parent.unlockNextButton(); }
|
private void createShortcuts() { if (!create) return; ShortcutData data; String tmpgn; for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); try { //The cloning guarantees that data.subgroup will not be null. //See ShortcutData.cloneString if (data.subgroup.length() > 0 && (data.subgroup.charAt(0) == '/' || data.subgroup.charAt(0) == '\\')) { tmpgn = groupName + data.subgroup; } else { tmpgn = groupName + File.separator + data.subgroup; } shortcut.setUserType(itsUserType); shortcut.setLinkName(data.name); shortcut.setLinkType(data.type); shortcut.setArguments(data.commandLine); shortcut.setDescription(data.description); shortcut.setIconLocation(data.iconFile, data.iconIndex); shortcut.setShowCommand(data.initialState); shortcut.setTargetPath(data.target); shortcut.setWorkingDirectory(data.workingDirectory); shortcut.setEncoding(data.deskTopEntryLinux_Encoding); shortcut.setMimetype(data.deskTopEntryLinux_MimeType); shortcut.setTerminal(data.deskTopEntryLinux_Terminal); shortcut.setTerminalOptions(data.deskTopEntryLinux_TerminalOptions); shortcut.setType(data.deskTopEntryLinux_Type); shortcut.setKdeSubstUID(data.deskTopEntryLinux_X_KDE_SubstituteUID); shortcut.setURL(data.deskTopEntryLinux_URL); shortcut.setCreateForAll(data.createForAll); if (data.addToGroup) { shortcut.setProgramGroup(tmpgn); } else { shortcut.setProgramGroup(""); } try { // ---------------------------------------------- // save the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut .isSelected())) { // save the shortcut shortcut.save(); // add the file and directory name to the file list String fileName = shortcut.getFileName(); files.add(0, fileName); File file = new File(fileName); File base = new File(shortcut.getBasePath()); Vector intermediates = new Vector(); //String directoryName = shortcut.getDirectoryCreated (); execFiles.add(new ExecutableFile(fileName, 2, ExecutableFile.WARN, new ArrayList(), false)); files.add(fileName); while ((file = file.getParentFile()) != null) { if (file.equals(base)) break; intermediates.add(file); } if (file != null) { for (Iterator iter = intermediates.iterator(); iter.hasNext();) files.add(0, iter.next().toString()); } } } catch (Exception exception) {} } catch (Throwable exception) { } } // try { if (execFiles != null) { FileExecutor executor = new FileExecutor(execFiles); // // TODO: Hi Guys, // TODO The following commented-out line sometimes produces an uncatchable // nullpointer Exception! // TODO evaluate for what reason the files should exec. // TODO if there is a serious explanation, why to do that, // TODO the code must be more robust //evaluate executor.executeFiles( ExecutableFile.NEVER, null ); } } catch (NullPointerException nep) { nep.printStackTrace(); } catch (RuntimeException cannot) { cannot.printStackTrace(); } }
| 3,241,831 |
private File getProgramsFolder(int userType) { String path = shortcut.getProgramsFolder(userType); return (new File(path)); //} //else //{ // TODO // 0pt. Test if KDE is installed. //boolean isKdeInstalled = UnixHelper.kdeIsInstalled(); // 1. Test if User can write into // File kdeRootShareApplinkDir = getKDERootShareApplinkDir(); // if so: return getKDERootShareApplinkDir() // else // return getKDEUsersShareApplinkDir() + //} //return(result); }
|
private File getProgramsFolder(int userType) { String path = shortcut.getProgramsFolder(userType); return (new File(path)); //} //else //{ // TODO // 0pt. Test if KDE is installed. //boolean isKdeInstalled = UnixHelper.kdeIsInstalled(); // 1. Test if User can write into // File kdeRootShareApplinkDir = getKDERootShareApplinkDir(); // if so: return getKDERootShareApplinkDir() // else // return getKDEUsersShareApplinkDir() + //} //return(result); }
| 3,241,832 |
private File getProgramsFolder(int userType) { String path = shortcut.getProgramsFolder(userType); return (new File(path)); //} //else //{ // TODO // 0pt. Test if KDE is installed. //boolean isKdeInstalled = UnixHelper.kdeIsInstalled(); // 1. Test if User can write into // File kdeRootShareApplinkDir = getKDERootShareApplinkDir(); // if so: return getKDERootShareApplinkDir() // else // return getKDEUsersShareApplinkDir() + //} //return(result); }
|
private File getProgramsFolder(int userType) { String path = shortcut.getProgramsFolder(userType); return (new File(path)); //} //else //{ // TODO // 0pt. Test if KDE is installed. //boolean isKdeInstalled = UnixHelper.kdeIsInstalled(); // 1. Test if User can write into // File kdeRootShareApplinkDir = getKDERootShareApplinkDir(); // if so: return getKDERootShareApplinkDir() // else // return getKDEUsersShareApplinkDir() + //} //return(result); }
| 3,241,833 |
private File getProgramsFolder(int userType) { String path = shortcut.getProgramsFolder(userType); return (new File(path)); //} //else //{ // TODO // 0pt. Test if KDE is installed. //boolean isKdeInstalled = UnixHelper.kdeIsInstalled(); // 1. Test if User can write into // File kdeRootShareApplinkDir = getKDERootShareApplinkDir(); // if so: return getKDERootShareApplinkDir() // else // return getKDEUsersShareApplinkDir() + //} //return(result); }
|
private File getProgramsFolder(int userType) { String path = shortcut.getProgramsFolder(userType); return (new File(path)); //} //else //{ // TODO // 0pt. Test if KDE is installed. //boolean isKdeInstalled = UnixHelper.kdeIsInstalled(); // 1. Test if User can write into // File kdeRootShareApplinkDir = getKDERootShareApplinkDir(); // if so: return getKDERootShareApplinkDir() // else // return getKDEUsersShareApplinkDir() + //} //return(result); }
| 3,241,834 |
public void makeXMLData(XMLElement panelRoot) { // ---------------------------------------------------- // if there are no shortcuts to create, shortcuts are // not supported, or we should simulate that they are // not supported, then we have nothing to add. Just // return // ---------------------------------------------------- if (!shortcutsToCreate || !shortcut.supported() || groupName == null || simulteNotSupported) { return; } ShortcutData data; XMLElement dataElement; // ---------------------------------------------------- // add the item that defines the name of the program group // ---------------------------------------------------- dataElement = new XMLElement(AUTO_KEY_PROGRAM_GROUP); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, groupName); panelRoot.addChild(dataElement); // ---------------------------------------------------- // add the details for each of the shortcuts // ---------------------------------------------------- for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); dataElement = new XMLElement(AUTO_KEY_SHORTCUT); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, data.name); dataElement.setAttribute(AUTO_ATTRIBUTE_GROUP, Boolean.valueOf(data.addToGroup) .toString()); dataElement.setAttribute(AUTO_ATTRIBUTE_TYPE, Integer.toString(data.type)); dataElement.setAttribute(AUTO_ATTRIBUTE_COMMAND, data.commandLine); dataElement.setAttribute(AUTO_ATTRIBUTE_DESCRIPTION, data.description); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON, data.iconFile); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON_INDEX, Integer.toString(data.iconIndex)); dataElement.setAttribute(AUTO_ATTRIBUTE_INITIAL_STATE, Integer .toString(data.initialState)); dataElement.setAttribute(AUTO_ATTRIBUTE_TARGET, data.target); dataElement.setAttribute(AUTO_ATTRIBUTE_WORKING_DIR, data.workingDirectory); // ---------------------------------------------- // add the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut.isSelected())) { panelRoot.addChild(dataElement); } } }
|
public void makeXMLData(XMLElement panelRoot) { // ---------------------------------------------------- // if there are no shortcuts to create, shortcuts are // not supported, or we should simulate that they are // not supported, then we have nothing to add. Just // return // ---------------------------------------------------- if (!shortcutsToCreate || !shortcut.supported() || (groupName == null) || simulteNotSupported) { return; } ShortcutData data; XMLElement dataElement; // ---------------------------------------------------- // add the item that defines the name of the program group // ---------------------------------------------------- dataElement = new XMLElement(AUTO_KEY_PROGRAM_GROUP); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, groupName); panelRoot.addChild(dataElement); // ---------------------------------------------------- // add the details for each of the shortcuts // ---------------------------------------------------- for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); dataElement = new XMLElement(AUTO_KEY_SHORTCUT); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, data.name); dataElement.setAttribute(AUTO_ATTRIBUTE_GROUP, Boolean.valueOf(data.addToGroup) .toString()); dataElement.setAttribute(AUTO_ATTRIBUTE_TYPE, Integer.toString(data.type)); dataElement.setAttribute(AUTO_ATTRIBUTE_COMMAND, data.commandLine); dataElement.setAttribute(AUTO_ATTRIBUTE_DESCRIPTION, data.description); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON, data.iconFile); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON_INDEX, Integer.toString(data.iconIndex)); dataElement.setAttribute(AUTO_ATTRIBUTE_INITIAL_STATE, Integer .toString(data.initialState)); dataElement.setAttribute(AUTO_ATTRIBUTE_TARGET, data.target); dataElement.setAttribute(AUTO_ATTRIBUTE_WORKING_DIR, data.workingDirectory); // ---------------------------------------------- // add the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut.isSelected())) { panelRoot.addChild(dataElement); } } }
| 3,241,836 |
public void makeXMLData(XMLElement panelRoot) { // ---------------------------------------------------- // if there are no shortcuts to create, shortcuts are // not supported, or we should simulate that they are // not supported, then we have nothing to add. Just // return // ---------------------------------------------------- if (!shortcutsToCreate || !shortcut.supported() || groupName == null || simulteNotSupported) { return; } ShortcutData data; XMLElement dataElement; // ---------------------------------------------------- // add the item that defines the name of the program group // ---------------------------------------------------- dataElement = new XMLElement(AUTO_KEY_PROGRAM_GROUP); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, groupName); panelRoot.addChild(dataElement); // ---------------------------------------------------- // add the details for each of the shortcuts // ---------------------------------------------------- for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); dataElement = new XMLElement(AUTO_KEY_SHORTCUT); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, data.name); dataElement.setAttribute(AUTO_ATTRIBUTE_GROUP, Boolean.valueOf(data.addToGroup) .toString()); dataElement.setAttribute(AUTO_ATTRIBUTE_TYPE, Integer.toString(data.type)); dataElement.setAttribute(AUTO_ATTRIBUTE_COMMAND, data.commandLine); dataElement.setAttribute(AUTO_ATTRIBUTE_DESCRIPTION, data.description); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON, data.iconFile); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON_INDEX, Integer.toString(data.iconIndex)); dataElement.setAttribute(AUTO_ATTRIBUTE_INITIAL_STATE, Integer .toString(data.initialState)); dataElement.setAttribute(AUTO_ATTRIBUTE_TARGET, data.target); dataElement.setAttribute(AUTO_ATTRIBUTE_WORKING_DIR, data.workingDirectory); // ---------------------------------------------- // add the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut.isSelected())) { panelRoot.addChild(dataElement); } } }
|
public void makeXMLData(XMLElement panelRoot) { // ---------------------------------------------------- // if there are no shortcuts to create, shortcuts are // not supported, or we should simulate that they are // not supported, then we have nothing to add. Just // return // ---------------------------------------------------- if (!shortcutsToCreate || !shortcut.supported() || groupName == null || simulteNotSupported) { return; } ShortcutData data; XMLElement dataElement; // ---------------------------------------------------- // add the item that defines the name of the program group // ---------------------------------------------------- dataElement = new XMLElement(AUTO_KEY_PROGRAM_GROUP); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, groupName); panelRoot.addChild(dataElement); // ---------------------------------------------------- // add the details for each of the shortcuts // ---------------------------------------------------- for (int i = 0; i < shortcuts.size(); i++) { data = (ShortcutData) shortcuts.elementAt(i); dataElement = new XMLElement(AUTO_KEY_SHORTCUT); dataElement.setAttribute(AUTO_ATTRIBUTE_NAME, data.name); dataElement.setAttribute(AUTO_ATTRIBUTE_GROUP, Boolean.valueOf(data.addToGroup) .toString()); dataElement.setAttribute(AUTO_ATTRIBUTE_TYPE, Integer.toString(data.type)); dataElement.setAttribute(AUTO_ATTRIBUTE_COMMAND, data.commandLine); dataElement.setAttribute(AUTO_ATTRIBUTE_DESCRIPTION, data.description); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON, data.iconFile); dataElement.setAttribute(AUTO_ATTRIBUTE_ICON_INDEX, Integer.toString(data.iconIndex)); dataElement.setAttribute(AUTO_ATTRIBUTE_INITIAL_STATE, Integer .toString(data.initialState)); dataElement.setAttribute(AUTO_ATTRIBUTE_TARGET, data.target); dataElement.setAttribute(AUTO_ATTRIBUTE_WORKING_DIR, data.workingDirectory); // ---------------------------------------------- // add the shortcut only if it is either not on // the desktop or if it is on the desktop and // the user has signalled that it is ok to place // shortcuts on the desktop. // ---------------------------------------------- if ((data.type != Shortcut.DESKTOP) || ((data.type == Shortcut.DESKTOP) && allowDesktopShortcut.isSelected())) { panelRoot.addChild(dataElement); } } }
| 3,241,837 |
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
|
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
| 3,241,838 |
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
|
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
| 3,241,839 |
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
|
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI(getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER)); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
| 3,241,840 |
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
|
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
| 3,241,841 |
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { parent.skipPanel (); } }
|
public void panelActivate() { if (firstTime) firstTime = false; else return; analyzeShortcutSpec(); if (shortcutsToCreate && !OsVersion.IS_OSX) { if (shortcut.supported() && !simulteNotSupported) { File allUsersProgramsFolder = getProgramsFolder(Shortcut.ALL_USERS); isRootUser = allUsersProgramsFolder.canWrite(); if (isRootUser) itsUserType = Shortcut.ALL_USERS; else itsUserType = Shortcut.CURRENT_USER; buildUI( getProgramsFolder(isRootUser ? Shortcut.ALL_USERS : Shortcut.CURRENT_USER) ); } else { if (skipIfNotSupported) { parent.skipPanel(); } else { buildAlternateUI(); parent.unlockNextButton(); parent.lockPrevButton(); } } } else { ; } }
| 3,241,842 |
private void readShortcutSpec() throws Exception { // open an input stream InputStream input = null; try { input = parent.getResource(TargetFactory.getCurrentOSPrefix() + SPEC_FILE_NAME); } catch (ResourceNotFoundException rnfE) { input = parent.getResource(SPEC_FILE_NAME); if (input == null) { haveShortcutSpec = false; return; } } // if( input == null ) // { // haveShortcutSpec = false; // return; // } // initialize the parser StdXMLParser parser = new StdXMLParser(); parser.setBuilder(new StdXMLBuilder()); parser.setValidator(new NonValidator()); parser.setReader(new StdXMLReader(input)); // get the data spec = (XMLElement) parser.parse(); // close the stream input.close(); haveShortcutSpec = true; }
|
private void readShortcutSpec() throws Exception { // open an input stream InputStream input = null; try { input = parent.getResource(TargetFactory.getCurrentOSPrefix() + SPEC_FILE_NAME); } catch (ResourceNotFoundException rnfE) { input = parent.getResource(SPEC_FILE_NAME); if (input == null) { haveShortcutSpec = false; return; } } // if( input == null ) // { // haveShortcutSpec = false; // return; // } // initialize the parser StdXMLParser parser = new StdXMLParser(); parser.setBuilder(new StdXMLBuilder()); parser.setValidator(new NonValidator()); parser.setReader(new StdXMLReader(input)); // get the data spec = (XMLElement) parser.parse(); // close the stream input.close(); haveShortcutSpec = true; }
| 3,241,843 |
private void readShortcutSpec() throws Exception { // open an input stream InputStream input = null; try { input = parent.getResource(TargetFactory.getCurrentOSPrefix() + SPEC_FILE_NAME); } catch (ResourceNotFoundException rnfE) { input = parent.getResource(SPEC_FILE_NAME); if (input == null) { haveShortcutSpec = false; return; } } // if( input == null ) // { // haveShortcutSpec = false; // return; // } // initialize the parser StdXMLParser parser = new StdXMLParser(); parser.setBuilder(new StdXMLBuilder()); parser.setValidator(new NonValidator()); parser.setReader(new StdXMLReader(input)); // get the data spec = (XMLElement) parser.parse(); // close the stream input.close(); haveShortcutSpec = true; }
|
private void readShortcutSpec() throws Exception {if (input == null) { haveShortcutSpec = false; return; } // open an input streamif (input == null) { haveShortcutSpec = false; return; } InputStream input = null;if (input == null) { haveShortcutSpec = false; return; } tryif (input == null) { haveShortcutSpec = false; return; } {if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } input = parent.getResource(TargetFactory.getCurrentOSPrefix() + SPEC_FILE_NAME);if (input == null) { haveShortcutSpec = false; return; } }if (input == null) { haveShortcutSpec = false; return; } catch (ResourceNotFoundException rnfE)if (input == null) { haveShortcutSpec = false; return; } {if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } input = parent.getResource(SPEC_FILE_NAME);if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } if (input == null)if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } {if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } haveShortcutSpec = false;if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } return;if (input == null) { haveShortcutSpec = false; return; } if (input == null) { haveShortcutSpec = false; return; } }if (input == null) { haveShortcutSpec = false; return; } }if (input == null) { haveShortcutSpec = false; return; } // if( input == null )if (input == null) { haveShortcutSpec = false; return; } // {if (input == null) { haveShortcutSpec = false; return; } //if (input == null) { haveShortcutSpec = false; return; } haveShortcutSpec = false;if (input == null) { haveShortcutSpec = false; return; } //if (input == null) { haveShortcutSpec = false; return; } return;if (input == null) { haveShortcutSpec = false; return; } // }if (input == null) { haveShortcutSpec = false; return; } // initialize the parserif (input == null) { haveShortcutSpec = false; return; } StdXMLParser parser = new StdXMLParser();if (input == null) { haveShortcutSpec = false; return; } parser.setBuilder(new StdXMLBuilder());if (input == null) { haveShortcutSpec = false; return; } parser.setValidator(new NonValidator());if (input == null) { haveShortcutSpec = false; return; } parser.setReader(new StdXMLReader(input));if (input == null) { haveShortcutSpec = false; return; } // get the dataif (input == null) { haveShortcutSpec = false; return; } spec = (XMLElement) parser.parse();if (input == null) { haveShortcutSpec = false; return; } // close the streamif (input == null) { haveShortcutSpec = false; return; } input.close();if (input == null) { haveShortcutSpec = false; return; } haveShortcutSpec = true; }
| 3,241,844 |
private void readShortcutSpec() throws Exception { // open an input stream InputStream input = null; try { input = parent.getResource(TargetFactory.getCurrentOSPrefix() + SPEC_FILE_NAME); } catch (ResourceNotFoundException rnfE) { input = parent.getResource(SPEC_FILE_NAME); if (input == null) { haveShortcutSpec = false; return; } } // if( input == null ) // { // haveShortcutSpec = false; // return; // } // initialize the parser StdXMLParser parser = new StdXMLParser(); parser.setBuilder(new StdXMLBuilder()); parser.setValidator(new NonValidator()); parser.setReader(new StdXMLReader(input)); // get the data spec = (XMLElement) parser.parse(); // close the stream input.close(); haveShortcutSpec = true; }
|
private void readShortcutSpec() throws Exception { // open an input stream InputStream input = null; try { input = parent.getResource(TargetFactory.getCurrentOSPrefix() + SPEC_FILE_NAME); } catch (ResourceNotFoundException rnfE) { input = parent.getResource(SPEC_FILE_NAME); if (input == null) { haveShortcutSpec = false; return; } } // if( input == null ) // { // haveShortcutSpec = false; // return; // } // initialize the parser StdXMLParser parser = new StdXMLParser(); parser.setBuilder(new StdXMLBuilder()); parser.setValidator(new NonValidator()); parser.setReader(StdXMLReader.stringReader(substitutedSpec)); // get the data spec = (XMLElement) parser.parse(); // close the stream input.close(); haveShortcutSpec = true; }
| 3,241,845 |
public void windowClosing(WindowEvent e) { if (Unpacker.isDiscardInterrupt() && interruptCount < MAX_INTERRUPT) { // But we should not interrupt. interruptCount++; return; } // We show an alert anyway if (!installdata.canClose) JOptionPane.showMessageDialog(null, langpack.getString("installer.quit.message"), langpack.getString("installer.warning"), JOptionPane.ERROR_MESSAGE); wipeAborted(); Housekeeper.getInstance().shutDown(0); }
|
public void windowClosing(WindowEvent e) { if (Unpacker.isDiscardInterrupt() && interruptCount < MAX_INTERRUPT) { // But we should not interrupt. interruptCount++; return; } // We show an alert anyway if (!installdata.canClose) JOptionPane.showMessageDialog(null, langpack.getString("installer.quit.message"), langpack.getString("installer.warning"), JOptionPane.ERROR_MESSAGE); wipeAborted(); Housekeeper.getInstance().shutDown(0); }
| 3,241,847 |
private void buildGUI() { // Sets the frame icon setIconImage(icons.getImageIcon("JFrameIcon").getImage()); // Prepares the glass pane to block the gui interaction when needed JPanel glassPane = (JPanel) getGlassPane(); glassPane.addMouseListener(new MouseAdapter() {}); glassPane.addMouseMotionListener(new MouseMotionAdapter() {}); glassPane.addKeyListener(new KeyAdapter() {}); glassPane.addFocusListener(new FocusAdapter() {}); // We set the layout & prepare the constraint object contentPane = (JPanel) getContentPane(); contentPane.setLayout(new BorderLayout()); // layout); // We add the panels container panelsContainer = new JPanel(); panelsContainer.setBorder(BorderFactory.createEmptyBorder(10, 10, 0, 10)); panelsContainer.setLayout(new GridLayout(1, 1)); contentPane.add(panelsContainer, BorderLayout.CENTER); // We put the first panel installdata.curPanelNumber = 0; IzPanel panel_0 = (IzPanel) installdata.panels.get(0); panelsContainer.add(panel_0); // We add the navigation buttons & labels NavigationHandler navHandler = new NavigationHandler(); JPanel navPanel = new JPanel(); navPanel.setLayout(new BoxLayout(navPanel, BoxLayout.X_AXIS)); navPanel.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createEmptyBorder(8, 8, 8, 8), BorderFactory.createTitledBorder(new EtchedLineBorder(), langpack .getString("installer.madewith") + " "))); navPanel.add(Box.createHorizontalGlue()); prevButton = ButtonFactory.createButton(langpack.getString("installer.prev"), icons .getImageIcon("stepback"), installdata.buttonsHColor); navPanel.add(prevButton); prevButton.addActionListener(navHandler); navPanel.add(Box.createRigidArea(new Dimension(5, 0))); nextButton = ButtonFactory.createButton(langpack.getString("installer.next"), icons .getImageIcon("stepforward"), installdata.buttonsHColor); navPanel.add(nextButton); nextButton.addActionListener(navHandler); navPanel.add(Box.createRigidArea(new Dimension(5, 0))); quitButton = ButtonFactory.createButton(langpack.getString("installer.quit"), icons .getImageIcon("stop"), installdata.buttonsHColor); navPanel.add(quitButton); quitButton.addActionListener(navHandler); contentPane.add(navPanel, BorderLayout.SOUTH); try { ResourceManager rm = ResourceManager.getInstance(); ImageIcon icon; try { icon = rm.getImageIconResource("Installer.image"); } catch (Exception e) // This is not that clean ... { icon = rm.getImageIconResource("Installer.image.0"); } if (icon != null) { JPanel imgPanel = new JPanel(); imgPanel.setLayout(new BorderLayout()); imgPanel.setBorder(BorderFactory.createEmptyBorder(10, 10, 0, 0)); iconLabel = new JLabel(icon); iconLabel.setBorder(BorderFactory.createLoweredBevelBorder()); imgPanel.add(iconLabel, BorderLayout.NORTH); contentPane.add(imgPanel, BorderLayout.WEST); } } catch (Exception e) { // ignore } loadImage(0); getRootPane().setDefaultButton(nextButton); }
|
this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); privatethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); voidthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); buildGUI()this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Setsthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); framethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); setIconImage(icons.getImageIcon("JFrameIcon").getImage());this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Preparesthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); glassthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); tothis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); blockthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); guithis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); interactionthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); whenthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); neededthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); JPanelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); glassPanethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); (JPanel)this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); getGlassPane();this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); glassPane.addMouseListener(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); MouseAdapter()this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {});this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); glassPane.addMouseMotionListener(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); MouseMotionAdapter()this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {});this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); glassPane.addKeyListener(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); KeyAdapter()this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {});this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); glassPane.addFocusListener(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); FocusAdapter()this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {});this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Wethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); setthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); layoutthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); &this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); preparethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); constraintthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); objectthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); contentPanethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); (JPanel)this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); getContentPane();this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); contentPane.setLayout(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BorderLayout());this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); layout);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Wethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); addthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panelsthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); containerthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panelsContainerthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); JPanel();this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panelsContainer.setBorder(BorderFactory.createEmptyBorder(10,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 10,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 0,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 10));this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panelsContainer.setLayout(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); GridLayout(1,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 1));this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); contentPane.add(panelsContainer,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BorderLayout.CENTER);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Wethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); putthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); firstthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); installdata.curPanelNumberthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 0;this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); IzPanelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panel_0this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); (IzPanel)this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); installdata.panels.get(0);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); panelsContainer.add(panel_0);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Wethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); addthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navigationthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); buttonsthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); &this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); labelsthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); NavigationHandlerthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navHandlerthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); NavigationHandler();this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); JPanelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); JPanel();this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.setLayout(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BoxLayout(navPanel,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BoxLayout.X_AXIS));this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createEmptyBorder(8,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 8,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 8,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 8),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BorderFactory.createTitledBorder(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); EtchedLineBorder(),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); langpackthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); .getString("installer.madewith")this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); +this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); "this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ")));this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.add(Box.createHorizontalGlue());this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); prevButtonthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ButtonFactory.createButton(langpack.getString("installer.prev"),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconsthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); .getImageIcon("stepback"),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); installdata.buttonsHColor);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.add(prevButton);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); prevButton.addActionListener(navHandler);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.add(Box.createRigidArea(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Dimension(5,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 0)));this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); nextButtonthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ButtonFactory.createButton(langpack.getString("installer.next"),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconsthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); .getImageIcon("stepforward"),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); installdata.buttonsHColor);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.add(nextButton);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); nextButton.addActionListener(navHandler);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.add(Box.createRigidArea(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Dimension(5,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 0)));this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); quitButtonthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ButtonFactory.createButton(langpack.getString("installer.quit"),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconsthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); .getImageIcon("stop"),this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); installdata.buttonsHColor);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); navPanel.add(quitButton);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); quitButton.addActionListener(navHandler);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); contentPane.add(navPanel,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BorderLayout.SOUTH);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); trythis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ResourceManagerthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); rmthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ResourceManager.getInstance();this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ImageIconthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); icon;this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); trythis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); rm.getImageIconResource("Installer.image");this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); }this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); catchthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); (Exceptionthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); e)this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Thisthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); isthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); notthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); thatthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); cleanthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ...this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); rm.getImageIconResource("Installer.image.0");this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); }this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ifthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); (iconthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); !=this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); null)this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); JPanelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); imgPanelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); JPanel();this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); imgPanel.setLayout(newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BorderLayout());this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); imgPanel.setBorder(BorderFactory.createEmptyBorder(10,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 10,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 0,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); 0));this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconLabelthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); =this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); newthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); JLabel(icon);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); iconLabel.setBorder(BorderFactory.createLoweredBevelBorder());this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); imgPanel.add(iconLabel,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BorderLayout.NORTH);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); contentPane.add(imgPanel,this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); BorderLayout.WEST);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); }this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); }this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); catchthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); (Exceptionthis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); e)this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); {this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); //this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); ignorethis.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); }this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); loadImage(0);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); getRootPane().setDefaultButton(nextButton);this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); }
| 3,241,848 |
public int executeFiles(int currentStage, AbstractUIHandler handler) { int exitStatus = 0; String[] output = new String[2]; String pathSep = System.getProperty("path.separator"); String osName = System.getProperty("os.name").toLowerCase(); //String permissions = (System.getProperty("user.name").equals("root")) ? "a+x" : "u+x"; String permissions = "a+x"; // loop through all executables Iterator efileIterator = files.iterator(); while ((exitStatus == 0) && efileIterator.hasNext()) { ExecutableFile efile = (ExecutableFile) efileIterator.next(); boolean deleteAfterwards = ! efile.keepFile; File file = new File(efile.path); Debug.trace("handeling executable file "+efile); // skip file if not for current OS (it might not have been installed at all) if (! OsConstraint.oneMatchesCurrentSystem (efile.osList)) continue; if(currentStage!=ExecutableFile.UNINSTALL) { // fix executable permission for unix systems if (pathSep.equals(":") && (!osName.startsWith("mac") || osName.endsWith("x"))) { Debug.trace("making file executable (setting executable flag)"); String[] params = {"/bin/chmod", permissions, file.toString()}; exitStatus = executeCommand(params, output); if (exitStatus != 0) { handler.emitError("file execution error", "Error executing \n"+ params[0]+" "+params[1]+" "+params[2]); continue; } } } // execute command in POSTINSTALL stage if ((exitStatus == 0) && ((currentStage == ExecutableFile.POSTINSTALL && efile.executionStage == ExecutableFile.POSTINSTALL) || (currentStage==ExecutableFile.UNINSTALL && efile.executionStage == ExecutableFile.UNINSTALL))) { List paramList = new ArrayList(); if (ExecutableFile.BIN == efile.type) paramList.add(file.toString()); else if (ExecutableFile.JAR == efile.type && null == efile.mainClass) { paramList.add(System.getProperty("java.home") + "/bin/java"); paramList.add("-jar"); paramList.add(file.toString()); } else if (ExecutableFile.JAR == efile.type && null != efile.mainClass) { paramList.add(System.getProperty("java.home") + "/bin/java"); paramList.add("-cp " + file.toString()); paramList.add(efile.mainClass); } if (null != efile.argList && !efile.argList.isEmpty()) paramList.addAll(efile.argList); String[] params = new String[paramList.size()]; for (int i = 0; i < paramList.size(); i++) params[i] = (String) paramList.get(i); exitStatus = executeCommand(params, output); // bring a dialog depending on return code and failure handling if (exitStatus != 0) { deleteAfterwards = false; String message = output[0] + "\n" + output[1]; if (message.length() == 1) message = new String("Failed to execute " + file.toString() + "."); if (efile.onFailure == ExecutableFile.ABORT) { // CHECKME: let the user decide or abort anyway? handler.emitError("file execution error", message); } else if (efile.onFailure == ExecutableFile.WARN) { // CHECKME: let the user decide or abort anyway? handler.emitWarning ("file execution error", message); exitStatus = 0; } else { if (handler.askQuestion (null, "Continue?", AbstractUIHandler.CHOICES_YES_NO) == AbstractUIHandler.ANSWER_YES) exitStatus = 0; } } } // POSTINSTALL executables will be deleted if (efile.executionStage == ExecutableFile.POSTINSTALL && deleteAfterwards) { if (file.canWrite()) file.delete(); } } return exitStatus; }
|
public int executeFiles(int currentStage, AbstractUIHandler handler) { int exitStatus = 0; String[] output = new String[2]; String pathSep = System.getProperty("path.separator"); String osName = System.getProperty("os.name").toLowerCase(); //String permissions = (System.getProperty("user.name").equals("root")) ? "a+x" : "u+x"; String permissions = "a+x"; // loop through all executables Iterator efileIterator = files.iterator(); while ((exitStatus == 0) && efileIterator.hasNext()) { ExecutableFile efile = (ExecutableFile) efileIterator.next(); boolean deleteAfterwards = ! efile.keepFile; File file = new File(efile.path); Debug.trace("handeling executable file "+efile); // skip file if not for current OS (it might not have been installed at all) if (! OsConstraint.oneMatchesCurrentSystem (efile.osList)) continue; if(currentStage!=ExecutableFile.UNINSTALL) { // fix executable permission for unix systems if (pathSep.equals(":") && (!osName.startsWith("mac") || osName.endsWith("x"))) { Debug.trace("making file executable (setting executable flag)"); String[] params = {"/bin/chmod", permissions, file.toString()}; exitStatus = executeCommand(params, output); if (exitStatus != 0) { handler.emitError("file execution error", "Error executing \n"+ params[0]+" "+params[1]+" "+params[2]); continue; } } } // execute command in POSTINSTALL stage if ((exitStatus == 0) && ((currentStage == ExecutableFile.POSTINSTALL && efile.executionStage == ExecutableFile.POSTINSTALL) || (currentStage==ExecutableFile.UNINSTALL && efile.executionStage == ExecutableFile.UNINSTALL))) { List paramList = new ArrayList(); if (ExecutableFile.BIN == efile.type) paramList.add(file.toString()); else if (ExecutableFile.JAR == efile.type && null == efile.mainClass) { paramList.add(System.getProperty("java.home") + "/bin/java"); paramList.add("-jar"); paramList.add(file.toString()); } else if (ExecutableFile.JAR == efile.type && null != efile.mainClass) { paramList.add(System.getProperty("java.home") + "/bin/java"); paramList.add("-cp"); paramList.add(file.toString()); paramList.add(efile.mainClass); } if (null != efile.argList && !efile.argList.isEmpty()) paramList.addAll(efile.argList); String[] params = new String[paramList.size()]; for (int i = 0; i < paramList.size(); i++) params[i] = (String) paramList.get(i); exitStatus = executeCommand(params, output); // bring a dialog depending on return code and failure handling if (exitStatus != 0) { deleteAfterwards = false; String message = output[0] + "\n" + output[1]; if (message.length() == 1) message = new String("Failed to execute " + file.toString() + "."); if (efile.onFailure == ExecutableFile.ABORT) { // CHECKME: let the user decide or abort anyway? handler.emitError("file execution error", message); } else if (efile.onFailure == ExecutableFile.WARN) { // CHECKME: let the user decide or abort anyway? handler.emitWarning ("file execution error", message); exitStatus = 0; } else { if (handler.askQuestion (null, "Continue?", AbstractUIHandler.CHOICES_YES_NO) == AbstractUIHandler.ANSWER_YES) exitStatus = 0; } } } // POSTINSTALL executables will be deleted if (efile.executionStage == ExecutableFile.POSTINSTALL && deleteAfterwards) { if (file.canWrite()) file.delete(); } } return exitStatus; }
| 3,241,849 |
public void afterPacks(AutomatedInstallData idata, AbstractUIProgressHandler handler) throws Exception { if (handler instanceof ExtendedUIProgressHandler && getProgressBarCallerCount() > 0) { String progress = getMsg("CustomActions.progress"); String tip = getMsg("CustomActions.tip"); if (tip.equals("CustomActions.tip") || progress.equals("CustomActions.progress")) { Debug .trace("No messages found for custom action progress bar interactions; skiped."); return; } ((ExtendedUIProgressHandler) handler).restartAction("Configure", progress, tip, getProgressBarCallerCount()); SimpleInstallerListener.doInformProgressBar = true; } }
|
public void afterPacks(AutomatedInstallData idata, AbstractUIProgressHandler handler) throws Exception { if (handler instanceof ExtendedUIProgressHandler && getProgressBarCallerCount() > 0) { String progress = getMsg("CustomActions.progress"); String tip = getMsg("CustomActions.tip"); if ("CustomActions.tip".equals(tip) || "CustomActions.progress".equals(progress)) { Debug .trace("No messages found for custom action progress bar interactions; skiped."); return; } ((ExtendedUIProgressHandler) handler).restartAction("Configure", progress, tip, getProgressBarCallerCount()); SimpleInstallerListener.doInformProgressBar = true; } }
| 3,241,850 |
public boolean valueExist(String key, String value) throws NativeLibException { try { this.getValue(currentRoot, key, value); } catch (NativeLibException ne) { String em = ne.getLibMessage(); if (em.equals("functionFailed.RegOpenKeyEx") || em.equals("functionFailed.RegQueryValueEx")) { return (false); } throw (ne); } return (true); }
|
public boolean valueExist(String key, String value) throws NativeLibException { try { this.getValue(currentRoot, key, value); } catch (NativeLibException ne) { String em = ne.getLibMessage(); if (em.equals("functionFailed.RegOpenKeyEx") || em.equals("functionFailed.RegQueryValueEx")) { return (false); } throw (ne); } return (true); }
| 3,241,851 |
private void addRuleField(XMLElement spec) { Vector forPacks = spec.getChildrenNamed(SELECTEDPACKS); Vector forOs = spec.getChildrenNamed(OS); XMLElement element = spec.getFirstChildNamed(SPEC); String variable = spec.getAttribute(VARIABLE); RuleInputField field = null; JLabel label; String layout; String set; String separator; String format; String validator = null; String message = null; boolean hasParams = false; String paramName = null; String paramValue = null; HashMap validateParamMap = null; Vector validateParams = null; String processor = null; int resultFormat = RuleInputField.DISPLAY_FORMAT; // ---------------------------------------------------- // extract the specification details // ---------------------------------------------------- if (element != null) { label = new JLabel(getText(element)); layout = element.getAttribute(RULE_LAYOUT); set = element.getAttribute(SET); // retrieve value of variable if not specified // (does not work here because of special format for set attribute) // if (set == null) // { // set = idata.getVariable (variable); // } separator = element.getAttribute(RULE_SEPARATOR); format = element.getAttribute(RULE_RESULT_FORMAT); if (format != null) { if (format.equals(RULE_PLAIN_STRING)) { resultFormat = RuleInputField.PLAIN_STRING; } else if (format.equals(RULE_DISPLAY_FORMAT)) { resultFormat = RuleInputField.DISPLAY_FORMAT; } else if (format.equals(RULE_SPECIAL_SEPARATOR)) { resultFormat = RuleInputField.SPECIAL_SEPARATOR; } else if (format.equals(RULE_ENCRYPTED)) { resultFormat = RuleInputField.ENCRYPTED; } } } // ---------------------------------------------------- // if there is no specification element, return without // doing anything. // ---------------------------------------------------- else { return; } // ---------------------------------------------------- // get the description and add it to the list of UI // elements if it exists. // ---------------------------------------------------- element = spec.getFirstChildNamed(DESCRIPTION); addDescription(element, forPacks, forOs); // ---------------------------------------------------- // get the validator and processor if they are defined // ---------------------------------------------------- element = spec.getFirstChildNamed(VALIDATOR); if (element != null) { validator = element.getAttribute(CLASS); message = getText(element); // ---------------------------------------------------------- // check and see if we have any parameters for this validator. // If so, then add them to validateParamMap. // ---------------------------------------------------------- validateParams = element.getChildrenNamed(RULE_PARAM); if (validateParams != null && validateParams.size() > 0 && validateParamMap == null) { validateParamMap = new HashMap(); hasParams = true; } for (Iterator it = validateParams.iterator(); it.hasNext();) { element = (XMLElement) it.next(); paramName = element.getAttribute(RULE_PARAM_NAME); paramValue = element.getAttribute(RULE_PARAM_VALUE); validateParamMap.put(paramName, paramValue); } } element = spec.getFirstChildNamed(PROCESSOR); if (element != null) { processor = element.getAttribute(CLASS); } // ---------------------------------------------------- // create an instance of RuleInputField based on the // extracted specifications, then add it to the list // of UI elements. // ---------------------------------------------------- if (hasParams) { field = new RuleInputField(layout, set, separator, validator, validateParamMap, processor, resultFormat, getToolkit(), idata); } else { field = new RuleInputField(layout, set, separator, validator, processor, resultFormat, getToolkit(), idata); } TwoColumnConstraints constraints = new TwoColumnConstraints(); constraints.position = TwoColumnConstraints.WEST; uiElements .add(new Object[] { null, FIELD_LABEL, null, constraints, label, forPacks, forOs}); TwoColumnConstraints constraints2 = new TwoColumnConstraints(); constraints2.position = TwoColumnConstraints.EAST; uiElements.add(new Object[] { null, RULE_FIELD, variable, constraints2, field, forPacks, forOs, null, null, message}); }
|
private void addRuleField(XMLElement spec) { Vector forPacks = spec.getChildrenNamed(SELECTEDPACKS); Vector forOs = spec.getChildrenNamed(OS); XMLElement element = spec.getFirstChildNamed(SPEC); String variable = spec.getAttribute(VARIABLE); RuleInputField field = null; JLabel label; String layout; String set; String separator; String format; String validator = null; String message = null; boolean hasParams = false; String paramName = null; String paramValue = null; HashMap validateParamMap = null; Vector validateParams = null; String processor = null; int resultFormat = RuleInputField.DISPLAY_FORMAT; // ---------------------------------------------------- // extract the specification details // ---------------------------------------------------- if (element != null) { label = new JLabel(getText(element)); layout = element.getAttribute(RULE_LAYOUT); set = element.getAttribute(SET); // retrieve value of variable if not specified // (does not work here because of special format for set attribute) // if (set == null) // { // set = idata.getVariable (variable); // } separator = element.getAttribute(RULE_SEPARATOR); format = element.getAttribute(RULE_RESULT_FORMAT); if (format != null) { if (format.equals(RULE_PLAIN_STRING)) { resultFormat = RuleInputField.PLAIN_STRING; } else if (format.equals(RULE_DISPLAY_FORMAT)) { resultFormat = RuleInputField.DISPLAY_FORMAT; } else if (format.equals(RULE_SPECIAL_SEPARATOR)) { resultFormat = RuleInputField.SPECIAL_SEPARATOR; } else if (format.equals(RULE_ENCRYPTED)) { resultFormat = RuleInputField.ENCRYPTED; } } } // ---------------------------------------------------- // if there is no specification element, return without // doing anything. // ---------------------------------------------------- else { return; } // ---------------------------------------------------- // get the description and add it to the list of UI // elements if it exists. // ---------------------------------------------------- element = spec.getFirstChildNamed(DESCRIPTION); addDescription(element, forPacks, forOs); // ---------------------------------------------------- // get the validator and processor if they are defined // ---------------------------------------------------- element = spec.getFirstChildNamed(VALIDATOR); if (element != null) { validator = element.getAttribute(CLASS); message = getText(element); // ---------------------------------------------------------- // check and see if we have any parameters for this validator. // If so, then add them to validateParamMap. // ---------------------------------------------------------- validateParams = element.getChildrenNamed(RULE_PARAM); if (validateParams != null && validateParams.size() > 0) { validateParamMap = new HashMap(); hasParams = true; } for (Iterator it = validateParams.iterator(); it.hasNext();) { element = (XMLElement) it.next(); paramName = element.getAttribute(RULE_PARAM_NAME); paramValue = element.getAttribute(RULE_PARAM_VALUE); validateParamMap.put(paramName, paramValue); } } element = spec.getFirstChildNamed(PROCESSOR); if (element != null) { processor = element.getAttribute(CLASS); } // ---------------------------------------------------- // create an instance of RuleInputField based on the // extracted specifications, then add it to the list // of UI elements. // ---------------------------------------------------- if (hasParams) { field = new RuleInputField(layout, set, separator, validator, validateParamMap, processor, resultFormat, getToolkit(), idata); } else { field = new RuleInputField(layout, set, separator, validator, processor, resultFormat, getToolkit(), idata); } TwoColumnConstraints constraints = new TwoColumnConstraints(); constraints.position = TwoColumnConstraints.WEST; uiElements .add(new Object[] { null, FIELD_LABEL, null, constraints, label, forPacks, forOs}); TwoColumnConstraints constraints2 = new TwoColumnConstraints(); constraints2.position = TwoColumnConstraints.EAST; uiElements.add(new Object[] { null, RULE_FIELD, variable, constraints2, field, forPacks, forOs, null, null, message}); }
| 3,241,852 |
private void addRuleField(XMLElement spec) { Vector forPacks = spec.getChildrenNamed(SELECTEDPACKS); Vector forOs = spec.getChildrenNamed(OS); XMLElement element = spec.getFirstChildNamed(SPEC); String variable = spec.getAttribute(VARIABLE); RuleInputField field = null; JLabel label; String layout; String set; String separator; String format; String validator = null; String message = null; boolean hasParams = false; String paramName = null; String paramValue = null; HashMap validateParamMap = null; Vector validateParams = null; String processor = null; int resultFormat = RuleInputField.DISPLAY_FORMAT; // ---------------------------------------------------- // extract the specification details // ---------------------------------------------------- if (element != null) { label = new JLabel(getText(element)); layout = element.getAttribute(RULE_LAYOUT); set = element.getAttribute(SET); // retrieve value of variable if not specified // (does not work here because of special format for set attribute) // if (set == null) // { // set = idata.getVariable (variable); // } separator = element.getAttribute(RULE_SEPARATOR); format = element.getAttribute(RULE_RESULT_FORMAT); if (format != null) { if (format.equals(RULE_PLAIN_STRING)) { resultFormat = RuleInputField.PLAIN_STRING; } else if (format.equals(RULE_DISPLAY_FORMAT)) { resultFormat = RuleInputField.DISPLAY_FORMAT; } else if (format.equals(RULE_SPECIAL_SEPARATOR)) { resultFormat = RuleInputField.SPECIAL_SEPARATOR; } else if (format.equals(RULE_ENCRYPTED)) { resultFormat = RuleInputField.ENCRYPTED; } } } // ---------------------------------------------------- // if there is no specification element, return without // doing anything. // ---------------------------------------------------- else { return; } // ---------------------------------------------------- // get the description and add it to the list of UI // elements if it exists. // ---------------------------------------------------- element = spec.getFirstChildNamed(DESCRIPTION); addDescription(element, forPacks, forOs); // ---------------------------------------------------- // get the validator and processor if they are defined // ---------------------------------------------------- element = spec.getFirstChildNamed(VALIDATOR); if (element != null) { validator = element.getAttribute(CLASS); message = getText(element); // ---------------------------------------------------------- // check and see if we have any parameters for this validator. // If so, then add them to validateParamMap. // ---------------------------------------------------------- validateParams = element.getChildrenNamed(RULE_PARAM); if (validateParams != null && validateParams.size() > 0 && validateParamMap == null) { validateParamMap = new HashMap(); hasParams = true; } for (Iterator it = validateParams.iterator(); it.hasNext();) { element = (XMLElement) it.next(); paramName = element.getAttribute(RULE_PARAM_NAME); paramValue = element.getAttribute(RULE_PARAM_VALUE); validateParamMap.put(paramName, paramValue); } } element = spec.getFirstChildNamed(PROCESSOR); if (element != null) { processor = element.getAttribute(CLASS); } // ---------------------------------------------------- // create an instance of RuleInputField based on the // extracted specifications, then add it to the list // of UI elements. // ---------------------------------------------------- if (hasParams) { field = new RuleInputField(layout, set, separator, validator, validateParamMap, processor, resultFormat, getToolkit(), idata); } else { field = new RuleInputField(layout, set, separator, validator, processor, resultFormat, getToolkit(), idata); } TwoColumnConstraints constraints = new TwoColumnConstraints(); constraints.position = TwoColumnConstraints.WEST; uiElements .add(new Object[] { null, FIELD_LABEL, null, constraints, label, forPacks, forOs}); TwoColumnConstraints constraints2 = new TwoColumnConstraints(); constraints2.position = TwoColumnConstraints.EAST; uiElements.add(new Object[] { null, RULE_FIELD, variable, constraints2, field, forPacks, forOs, null, null, message}); }
|
private void addRuleField(XMLElement spec) { Vector forPacks = spec.getChildrenNamed(SELECTEDPACKS); Vector forOs = spec.getChildrenNamed(OS); XMLElement element = spec.getFirstChildNamed(SPEC); String variable = spec.getAttribute(VARIABLE); RuleInputField field = null; JLabel label; String layout; String set; String separator; String format; String validator = null; String message = null; boolean hasParams = false; String paramName = null; String paramValue = null; HashMap validateParamMap = null; Vector validateParams = null; String processor = null; int resultFormat = RuleInputField.DISPLAY_FORMAT; // ---------------------------------------------------- // extract the specification details // ---------------------------------------------------- if (element != null) { label = new JLabel(getText(element)); layout = element.getAttribute(RULE_LAYOUT); set = element.getAttribute(SET); // retrieve value of variable if not specified // (does not work here because of special format for set attribute) // if (set == null) // { // set = idata.getVariable (variable); // } separator = element.getAttribute(RULE_SEPARATOR); format = element.getAttribute(RULE_RESULT_FORMAT); if (format != null) { if (format.equals(RULE_PLAIN_STRING)) { resultFormat = RuleInputField.PLAIN_STRING; } else if (format.equals(RULE_DISPLAY_FORMAT)) { resultFormat = RuleInputField.DISPLAY_FORMAT; } else if (format.equals(RULE_SPECIAL_SEPARATOR)) { resultFormat = RuleInputField.SPECIAL_SEPARATOR; } else if (format.equals(RULE_ENCRYPTED)) { resultFormat = RuleInputField.ENCRYPTED; } } } // ---------------------------------------------------- // if there is no specification element, return without // doing anything. // ---------------------------------------------------- else { return; } // ---------------------------------------------------- // get the description and add it to the list of UI // elements if it exists. // ---------------------------------------------------- element = spec.getFirstChildNamed(DESCRIPTION); addDescription(element, forPacks, forOs); // ---------------------------------------------------- // get the validator and processor if they are defined // ---------------------------------------------------- element = spec.getFirstChildNamed(VALIDATOR); if (element != null) { validator = element.getAttribute(CLASS); message = getText(element); // ---------------------------------------------------------- // check and see if we have any parameters for this validator. // If so, then add them to validateParamMap. // ---------------------------------------------------------- validateParams = element.getChildrenNamed(RULE_PARAM); if (validateParams != null && validateParams.size() > 0 && validateParamMap == null) { validateParamMap = new HashMap(); hasParams = true; } for (Iterator it = validateParams.iterator(); it.hasNext();) { element = (XMLElement) it.next(); paramName = element.getAttribute(RULE_PARAM_NAME); paramValue = element.getAttribute(RULE_PARAM_VALUE); validateParamMap.put(paramName, paramValue); } } element = spec.getFirstChildNamed(PROCESSOR); if (element != null) { processor = element.getAttribute(CLASS); } // ---------------------------------------------------- // create an instance of RuleInputField based on the // extracted specifications, then add it to the list // of UI elements. // ---------------------------------------------------- if (hasParams) { field = new RuleInputField(layout, set, separator, validator, validateParamMap, processor, resultFormat, getToolkit(), idata); } else { field = new RuleInputField(layout, set, separator, validator, processor, resultFormat, getToolkit(), idata); } TwoColumnConstraints constraints = new TwoColumnConstraints(); constraints.position = TwoColumnConstraints.WEST; uiElements .add(new Object[] { null, FIELD_LABEL, null, constraints, label, forPacks, forOs}); TwoColumnConstraints constraints2 = new TwoColumnConstraints(); constraints2.position = TwoColumnConstraints.EAST; uiElements.add(new Object[] { null, RULE_FIELD, variable, constraints2, field, forPacks, forOs, null, null, message}); }
| 3,241,853 |
private void addRuleField(XMLElement spec) { Vector forPacks = spec.getChildrenNamed(SELECTEDPACKS); Vector forOs = spec.getChildrenNamed(OS); XMLElement element = spec.getFirstChildNamed(SPEC); String variable = spec.getAttribute(VARIABLE); RuleInputField field = null; JLabel label; String layout; String set; String separator; String format; String validator = null; String message = null; boolean hasParams = false; String paramName = null; String paramValue = null; HashMap validateParamMap = null; Vector validateParams = null; String processor = null; int resultFormat = RuleInputField.DISPLAY_FORMAT; // ---------------------------------------------------- // extract the specification details // ---------------------------------------------------- if (element != null) { label = new JLabel(getText(element)); layout = element.getAttribute(RULE_LAYOUT); set = element.getAttribute(SET); // retrieve value of variable if not specified // (does not work here because of special format for set attribute) // if (set == null) // { // set = idata.getVariable (variable); // } separator = element.getAttribute(RULE_SEPARATOR); format = element.getAttribute(RULE_RESULT_FORMAT); if (format != null) { if (format.equals(RULE_PLAIN_STRING)) { resultFormat = RuleInputField.PLAIN_STRING; } else if (format.equals(RULE_DISPLAY_FORMAT)) { resultFormat = RuleInputField.DISPLAY_FORMAT; } else if (format.equals(RULE_SPECIAL_SEPARATOR)) { resultFormat = RuleInputField.SPECIAL_SEPARATOR; } else if (format.equals(RULE_ENCRYPTED)) { resultFormat = RuleInputField.ENCRYPTED; } } } // ---------------------------------------------------- // if there is no specification element, return without // doing anything. // ---------------------------------------------------- else { return; } // ---------------------------------------------------- // get the description and add it to the list of UI // elements if it exists. // ---------------------------------------------------- element = spec.getFirstChildNamed(DESCRIPTION); addDescription(element, forPacks, forOs); // ---------------------------------------------------- // get the validator and processor if they are defined // ---------------------------------------------------- element = spec.getFirstChildNamed(VALIDATOR); if (element != null) { validator = element.getAttribute(CLASS); message = getText(element); // ---------------------------------------------------------- // check and see if we have any parameters for this validator. // If so, then add them to validateParamMap. // ---------------------------------------------------------- validateParams = element.getChildrenNamed(RULE_PARAM); if (validateParams != null && validateParams.size() > 0 && validateParamMap == null) { validateParamMap = new HashMap(); hasParams = true; } for (Iterator it = validateParams.iterator(); it.hasNext();) { element = (XMLElement) it.next(); paramName = element.getAttribute(RULE_PARAM_NAME); paramValue = element.getAttribute(RULE_PARAM_VALUE); validateParamMap.put(paramName, paramValue); } } element = spec.getFirstChildNamed(PROCESSOR); if (element != null) { processor = element.getAttribute(CLASS); } // ---------------------------------------------------- // create an instance of RuleInputField based on the // extracted specifications, then add it to the list // of UI elements. // ---------------------------------------------------- if (hasParams) { field = new RuleInputField(layout, set, separator, validator, validateParamMap, processor, resultFormat, getToolkit(), idata); } else { field = new RuleInputField(layout, set, separator, validator, processor, resultFormat, getToolkit(), idata); } TwoColumnConstraints constraints = new TwoColumnConstraints(); constraints.position = TwoColumnConstraints.WEST; uiElements .add(new Object[] { null, FIELD_LABEL, null, constraints, label, forPacks, forOs}); TwoColumnConstraints constraints2 = new TwoColumnConstraints(); constraints2.position = TwoColumnConstraints.EAST; uiElements.add(new Object[] { null, RULE_FIELD, variable, constraints2, field, forPacks, forOs, null, null, message}); }
|
private void addRuleField(XMLElement spec) { Vector forPacks = spec.getChildrenNamed(SELECTEDPACKS); Vector forOs = spec.getChildrenNamed(OS); XMLElement element = spec.getFirstChildNamed(SPEC); String variable = spec.getAttribute(VARIABLE); RuleInputField field = null; JLabel label; String layout; String set; String separator; String format; String validator = null; String message = null; boolean hasParams = false; String paramName = null; String paramValue = null; HashMap validateParamMap = null; Vector validateParams = null; String processor = null; int resultFormat = RuleInputField.DISPLAY_FORMAT; // ---------------------------------------------------- // extract the specification details // ---------------------------------------------------- if (element != null) { label = new JLabel(getText(element)); layout = element.getAttribute(RULE_LAYOUT); set = element.getAttribute(SET); // retrieve value of variable if not specified // (does not work here because of special format for set attribute) // if (set == null) // { // set = idata.getVariable (variable); // } separator = element.getAttribute(RULE_SEPARATOR); format = element.getAttribute(RULE_RESULT_FORMAT); if (format != null) { if (format.equals(RULE_PLAIN_STRING)) { resultFormat = RuleInputField.PLAIN_STRING; } else if (format.equals(RULE_DISPLAY_FORMAT)) { resultFormat = RuleInputField.DISPLAY_FORMAT; } else if (format.equals(RULE_SPECIAL_SEPARATOR)) { resultFormat = RuleInputField.SPECIAL_SEPARATOR; } else if (format.equals(RULE_ENCRYPTED)) { resultFormat = RuleInputField.ENCRYPTED; } } } // ---------------------------------------------------- // if there is no specification element, return without // doing anything. // ---------------------------------------------------- else { return; } // ---------------------------------------------------- // get the description and add it to the list of UI // elements if it exists. // ---------------------------------------------------- element = spec.getFirstChildNamed(DESCRIPTION); addDescription(element, forPacks, forOs); // ---------------------------------------------------- // get the validator and processor if they are defined // ---------------------------------------------------- element = spec.getFirstChildNamed(VALIDATOR); if (element != null) { validator = element.getAttribute(CLASS); message = getText(element); // ---------------------------------------------------------- // check and see if we have any parameters for this validator. // If so, then add them to validateParamMap. // ---------------------------------------------------------- validateParams = element.getChildrenNamed(RULE_PARAM); if (validateParams != null && validateParams.size() > 0 && validateParamMap == null) { validateParamMap = new HashMap(); hasParams = true; } for (Iterator it = validateParams.iterator(); it.hasNext();) { element = (XMLElement) it.next(); paramName = element.getAttribute(RULE_PARAM_NAME); paramValue = element.getAttribute(RULE_PARAM_VALUE); validateParamMap.put(paramName, paramValue); } } element = spec.getFirstChildNamed(PROCESSOR); if (element != null) { processor = element.getAttribute(CLASS); } // ---------------------------------------------------- // create an instance of RuleInputField based on the // extracted specifications, then add it to the list // of UI elements. // ---------------------------------------------------- if (hasParams) { field = new RuleInputField(layout, set, separator, validator, validateParamMap, processor, resultFormat, getToolkit(), idata); } else { field = new RuleInputField(layout, set, separator, validator, processor, resultFormat, getToolkit(), idata); } TwoColumnConstraints constraints = new TwoColumnConstraints(); constraints.position = TwoColumnConstraints.WEST; uiElements .add(new Object[] { null, FIELD_LABEL, null, constraints, label, forPacks, forOs}); TwoColumnConstraints constraints2 = new TwoColumnConstraints(); constraints2.position = TwoColumnConstraints.EAST; uiElements.add(new Object[] { null, RULE_FIELD, variable, constraints2, field, forPacks, forOs, null, null, message}); }
| 3,241,854 |
public void returnObject(Object key, Object obj) throws Exception { // grab the pool (list) of objects associated with the given key CursorableLinkedList pool = null; synchronized(this) { pool = (CursorableLinkedList)(_poolMap.get(key)); // if it doesn't exist, create it if(null == pool) { pool = new CursorableLinkedList(); _poolMap.put(key, pool); _poolList.add(key); } } // if we need to validate this object, do so boolean success = true; // whether or not this object passed validation if((_testOnReturn && !_factory.validateObject(key, obj))) { success = false; try { _factory.destroyObject(key, obj); } catch(Exception e) { // ignored } } else { try { _factory.passivateObject(key, obj); } catch(Exception e) { success = false; } } boolean shouldDestroy = false; synchronized(this) { // subtract one from the total and keyed active counts _totalActive--; Integer active = (Integer)(_activeMap.get(key)); if(null == active) { // do nothing, either null or zero is OK } else if(active.intValue() <= 1) { _activeMap.remove(key); } else { _activeMap.put(key, new Integer(active.intValue() - 1)); } // if there's no space in the pool, flag the object // for destruction // else if we passivated succesfully, return it to the pool if(_maxIdle >= 0 && (pool.size() >= _maxIdle)) { shouldDestroy = true; } else if(success) { pool.addFirst(new ObjectTimestampPair(obj)); _totalIdle++; } notifyAll(); } if(shouldDestroy) { try { _factory.destroyObject(key, obj); } catch(Exception e) { // ignored? } } }
|
public void returnObject(Object key, Object obj) throws Exception { // grab the pool (list) of objects associated with the given key CursorableLinkedList pool = null; synchronized(this) { pool = (CursorableLinkedList)(_poolMap.get(key)); // if it doesn't exist, create it if(null == pool) { pool = new CursorableLinkedList(); _poolMap.put(key, pool); _poolList.add(key); } } // if we need to validate this object, do so boolean success = true; // whether or not this object passed validation if((_testOnReturn && !_factory.validateObject(key, obj))) { success = false; try { _factory.destroyObject(key, obj); } catch(Exception e) { // ignored } } else { try { _factory.passivateObject(key, obj); } catch(Exception e) { success = false; } } boolean shouldDestroy = false; synchronized(this) { // subtract one from the total and keyed active counts _totalActive--; Integer active = (Integer)(_activeMap.get(key)); if(null == active) { // do nothing, either null or zero is OK } else if(active.intValue() <= 1) { _activeMap.remove(key); } else { _activeMap.put(key, new Integer(active.intValue() - 1)); } // if there's no space in the pool, flag the object // for destruction // else if we passivated succesfully, return it to the pool if(_maxIdle >= 0 && (pool.size() >= _maxIdle)) { shouldDestroy = true; } else if(success) { pool.addFirst(new ObjectTimestampPair(obj)); _totalIdle++; } notifyAll(); } if(shouldDestroy) { try { _factory.destroyObject(key, obj); } catch(Exception e) { // ignored? } } }
| 3,241,855 |
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
|
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
| 3,241,857 |
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
|
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
| 3,241,858 |
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
|
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } else { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
| 3,241,859 |
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
|
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
| 3,241,860 |
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
|
private static PrintWriter createLogFile( ) { String tempDir = System.getProperty( "java.io.tmpdir" ); File tempDirFile = new File( tempDir ); try { tempDirFile.mkdirs( ); } catch( RuntimeException e1 ) { e1.printStackTrace( ); } String logfilename = LOGFILENAME; System.out.println( "creating Logfile: '" + logfilename + "' in: '" + tempDir + "'" ); File out = new File( tempDir, logfilename ); if( tempDirFile.canWrite( ) ) { try { fw = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( out ), "UTF-8" ) ); logfile = setLogFile( new PrintWriter( fw ) ); } catch( Exception e ) { logfile = null; e.printStackTrace( ); } } else { logfile = null; System.err.println( "Fatal: cannot write File: '" + logfilename + "' into: " + tempDirFile ); } return logfile; }
| 3,241,861 |
public static PrintWriter getLogFile( ) { logfile = (PrintWriter) System.getProperties( ).get( IZPACK_LOGFILE ); return logfile; }
|
public static PrintWriter getLogFile( ) { PrintWriter logfile = (PrintWriter) System.getProperties().get(IZPACK_LOGFILE); return logfile; }
| 3,241,862 |
public static synchronized PrintWriter setLogFile( PrintWriter aLogFile ) { System.getProperties( ).put( IZPACK_LOGFILE, aLogFile ); logfile = (PrintWriter) System.getProperties( ).get( IZPACK_LOGFILE ); if( logfile == null ) { System.err.println( "Set::logfile == null" ); } return logfile; }
|
public static synchronized PrintWriter setLogFile( PrintWriter aLogFile ) { System.getProperties( ).put( IZPACK_LOGFILE, aLogFile ); PrintWriter logfile = (PrintWriter) System.getProperties().get(IZPACK_LOGFILE); if( logfile == null ) { System.err.println( "Set::logfile == null" ); } return logfile; }
| 3,241,863 |
private void askUninstallerRemoval() throws Exception { // Initialisations InputStream in = getClass().getResourceAsStream("/jarlocation.log"); InputStreamReader inReader = new InputStreamReader(in); BufferedReader reader = new BufferedReader(inReader); // We delete File jar = new File(reader.readLine()); File path = new File(reader.readLine()); File inst = new File(installPath); jar.deleteOnExit(); path.deleteOnExit(); inst.deleteOnExit(); }
|
private void askUninstallerRemoval() throws Exception { // Initialisations InputStream in = Destroyer.class.getResourceAsStream("/jarlocation.log"); InputStreamReader inReader = new InputStreamReader(in); BufferedReader reader = new BufferedReader(inReader); // We delete File jar = new File(reader.readLine()); File path = new File(reader.readLine()); File inst = new File(installPath); jar.deleteOnExit(); path.deleteOnExit(); inst.deleteOnExit(); }
| 3,241,864 |
private ArrayList getExecutablesList() throws Exception { ArrayList executables = new ArrayList(); ObjectInputStream in = new ObjectInputStream(getClass().getResourceAsStream("/executables")); int num = in.readInt(); for (int i = 0; i < num; i++) { ExecutableFile file = (ExecutableFile) in.readObject(); executables.add(file); } return executables; }
|
private ArrayList getExecutablesList() throws Exception { ArrayList executables = new ArrayList(); ObjectInputStream in = new ObjectInputStream(Destroyer.class.getResourceAsStream("/executables")); int num = in.readInt(); for (int i = 0; i < num; i++) { ExecutableFile file = (ExecutableFile) in.readObject(); executables.add(file); } return executables; }
| 3,241,865 |
private ArrayList getFilesList() throws Exception { // Initialisations TreeSet files = new TreeSet(Collections.reverseOrder()); InputStream in = getClass().getResourceAsStream("/install.log"); InputStreamReader inReader = new InputStreamReader(in); BufferedReader reader = new BufferedReader(inReader); // We skip the first line (the installation path) reader.readLine(); // We read it String read = reader.readLine(); while (read != null) { files.add(new File(read)); read = reader.readLine(); } // We return it return new ArrayList(files); }
|
private ArrayList getFilesList() throws Exception { // Initialisations TreeSet files = new TreeSet(Collections.reverseOrder()); InputStream in = Destroyer.class.getResourceAsStream("/install.log"); InputStreamReader inReader = new InputStreamReader(in); BufferedReader reader = new BufferedReader(inReader); // We skip the first line (the installation path) reader.readLine(); // We read it String read = reader.readLine(); while (read != null) { files.add(new File(read)); read = reader.readLine(); } // We return it return new ArrayList(files); }
| 3,241,866 |
private List [] getListenerLists() throws Exception { ArrayList [] uninstaller = new ArrayList[] {new ArrayList(),new ArrayList()}; // Load listeners if exist InputStream in; ObjectInputStream objIn; in = getClass().getResourceAsStream("/uninstallerListeners"); if( in != null ) { objIn = new ObjectInputStream(in); List listeners = (List)objIn.readObject(); objIn.close(); Iterator iter = listeners.iterator(); while( iter != null && iter.hasNext()) { Class clazz = Class.forName(((String) iter.next())); UninstallerListener ul = (UninstallerListener) clazz.newInstance(); if( ul.isFileListener()) uninstaller[1].add( ul ); uninstaller[0].add( ul ); } } return uninstaller; }
|
private List [] getListenerLists() throws Exception { ArrayList [] uninstaller = new ArrayList[] {new ArrayList(),new ArrayList()}; // Load listeners if exist InputStream in; ObjectInputStream objIn; in = Destroyer.class.getResourceAsStream("/uninstallerListeners"); if( in != null ) { objIn = new ObjectInputStream(in); List listeners = (List)objIn.readObject(); objIn.close(); Iterator iter = listeners.iterator(); while( iter != null && iter.hasNext()) { Class clazz = Class.forName(((String) iter.next())); UninstallerListener ul = (UninstallerListener) clazz.newInstance(); if( ul.isFileListener()) uninstaller[1].add( ul ); uninstaller[0].add( ul ); } } return uninstaller; }
| 3,241,867 |
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString(parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
|
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString(parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
| 3,241,868 |
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString(parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
|
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString( parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
| 3,241,869 |
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString(parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
|
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString(parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
| 3,241,870 |
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString(parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
|
public InstallPanel(InstallerFrame parent, InstallData idata) { super(parent, idata); // We initialize our layout layout = new GridBagLayout(); gbConstraints = new GridBagConstraints(); setLayout(layout); int row = 1; this.tipLabel = new JLabel(parent.langpack.getString("InstallPanel.tip"), parent.icons.getImageIcon("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.fill = GridBagConstraints.NONE; gbConstraints.anchor = GridBagConstraints.NORTHWEST; layout.addLayoutComponent(this.tipLabel, gbConstraints); add(this.tipLabel); this.packOpLabel = new JLabel(" ", JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.SOUTHWEST; layout.addLayoutComponent(this.packOpLabel, gbConstraints); add(this.packOpLabel); this.packProgressBar = new JProgressBar(); this.packProgressBar.setStringPainted(true); this.packProgressBar.setString(parent.langpack.getString("InstallPanel.begin")); this.packProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.packProgressBar, gbConstraints); add(this.packProgressBar); // make sure there is some space between the progress bars JSeparator sep = new JSeparator (); Dimension dim = new Dimension (0, 10); sep.setPreferredSize (dim); sep.setMinimumSize (dim); sep.setMaximumSize (dim); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); layout.addLayoutComponent(sep, gbConstraints); add(sep); this.overallOpLabel = new JLabel(parent.langpack.getString ("InstallPanel.progress"), parent.icons.getImageIcon ("information"), JLabel.TRAILING); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTHWEST; gbConstraints.fill = GridBagConstraints.NONE; layout.addLayoutComponent(this.overallOpLabel, gbConstraints); add(this.overallOpLabel); this.overallProgressBar = new JProgressBar(); this.overallProgressBar.setStringPainted(true); this.overallProgressBar.setString(""); this.overallProgressBar.setValue(0); parent.buildConstraints(gbConstraints, 0, row++, 2, 1, 1.0, 0.0); gbConstraints.anchor = GridBagConstraints.NORTH; gbConstraints.fill = GridBagConstraints.HORIZONTAL; layout.addLayoutComponent(this.overallProgressBar, gbConstraints); add(this.overallProgressBar); }
| 3,241,871 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.