Ignore:
Timestamp:
May 20, 2013, 1:24:58 PM (12 years ago)
Author:
alloc
Message:

AEI2.14:

Location:
java/installer2/src/net/oni2/aeinstaller/gui
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • java/installer2/src/net/oni2/aeinstaller/gui/MainWin.java

    r871 r873  
    4848import javax.swing.ToolTipManager;
    4949import javax.swing.filechooser.FileFilter;
     50import javax.swing.text.html.CSS;
    5051
    5152import net.oni2.SettingsManager;
     
    8283import net.oni2.platformtools.applicationinvoker.ERuntimeNotInstalledException;
    8384import net.oni2.resourcebundle.UTF8ResourceBundleLoader;
     85import net.oni2.swingcomponents.HTMLLinkLabel;
    8486
    8587import org.javabuilders.BuildResult;
     
    460462
    461463        @SuppressWarnings("unused")
     464        private void showTips() {
     465                if (SettingsManager.getInstance().get("showTips", true)) {
     466                        HTMLLinkLabel text = new HTMLLinkLabel();
     467                        text.setCssAttribute("h2", CSS.Attribute.MARGIN_TOP, "0");
     468                        text.setCssAttribute("h3", CSS.Attribute.MARGIN_TOP, "0");
     469                        text.setCssAttribute("ul", CSS.Attribute.MARGIN_TOP, "0");
     470                        text.setCssAttribute("ul", CSS.Attribute.MARGIN_LEFT, "20");
     471                        text.setCssAttribute("ul li", CSS.Attribute.MARGIN_TOP, "10");
     472                        text.setCssAttribute("ul li", CSS.Attribute.PADDING_LEFT, "10");
     473                        text.setText(bundle.getString("startupTips.text"));
     474                        JOptionPane.showMessageDialog(this, text,
     475                                        bundle.getString("startupTips.title"),
     476                                        JOptionPane.INFORMATION_MESSAGE);
     477                }
     478        }
     479
     480        @SuppressWarnings("unused")
    462481        private void focus() {
    463482                SwingUtilities.invokeLater(new Runnable() {
  • java/installer2/src/net/oni2/aeinstaller/gui/MainWin.yml

    r860 r873  
    66  locationRelativeTo: null
    77  defaultCloseOperation: doNothingOnClose
    8   onWindowOpened: [execDepotUpdate,checkCorePackages,infoCorePackages,checkInitialize,initialize,checkUpdates,doUpdate,refreshToolsMenu,showNewPackages,focus]
     8  onWindowOpened: [execDepotUpdate,checkCorePackages,infoCorePackages,checkInitialize,initialize,checkUpdates,doUpdate,refreshToolsMenu,showNewPackages,showTips,focus]
    99  onWindowClosing: [saveLocalData,exit]
    1010  iconImage: img.ae
  • java/installer2/src/net/oni2/aeinstaller/gui/settings/SettingsDialog.java

    r872 r873  
    4141        private JCheckBox chkNotifyNewPackagesOnStart;
    4242        private JCheckBox chkNotifyDepsAfterInstall;
     43        private JCheckBox chkShowTipsAtStart;
    4344        private JCheckBox chkCopyIntro;
    4445        private JCheckBox chkCopyOutro;
     
    8687                chkNotifyDepsAfterInstall.setSelected(set.get("notifyDepsAfterInstall",
    8788                                false));
     89                chkShowTipsAtStart.setSelected(set.get("showTips", true));
    8890                chkCopyIntro.setSelected(set.get("copyintro", false));
    8991                chkCopyOutro.setSelected(set.get("copyoutro", true));
     
    145147                set.put("notifyDepsAfterInstall",
    146148                                chkNotifyDepsAfterInstall.isSelected());
     149                set.put("showTips", chkShowTipsAtStart.isSelected());
    147150                set.put("copyintro", chkCopyIntro.isSelected());
    148151                set.put("copyoutro", chkCopyOutro.isSelected());
  • java/installer2/src/net/oni2/aeinstaller/gui/settings/SettingsDialog.yml

    r860 r873  
    1414      - JCheckBox(name=chkNotifyNewPackagesOnStart, horizontalTextPosition=LEADING, text=lblNotifyNewPackagesOnStart)
    1515      - JCheckBox(name=chkNotifyDepsAfterInstall, horizontalTextPosition=LEADING, text=lblNotifyDepsAfterInstall, toolTipText=lblNotifyDepsAfterInstall.tooltip)
     16      - JCheckBox(name=chkShowTipsAtStart, horizontalTextPosition=LEADING, text=lblShowTipsAtStart)
    1617      - JCheckBox(name=chkCopyIntro, horizontalTextPosition=LEADING, text=lblCopyIntro)
    1718      - JCheckBox(name=chkCopyOutro, horizontalTextPosition=LEADING, text=lblCopyOutro)
     
    2122           >chkNotifyNewPackagesOnStart  [pref]
    2223           >chkNotifyDepsAfterInstall    [pref]
     24           >chkShowTipsAtStart           [pref]
    2325           >chkCopyIntro                 [pref]
    2426           >chkCopyOutro                 [pref]
Note: See TracChangeset for help on using the changeset viewer.