diff options
author | Rüdiger Timm <rt@openoffice.org> | 2005-09-09 01:45:45 +0000 |
---|---|---|
committer | Rüdiger Timm <rt@openoffice.org> | 2005-09-09 01:45:45 +0000 |
commit | e3cfa58d8a5149570e966f72201d9cc918496b69 (patch) | |
tree | 84f3c7b982c6d555ce34b419f6880cac81bb8673 /scripting | |
parent | 93017881615aeba0c0d809750bc02c3baafd61db (diff) |
INTEGRATION: CWS ooo19126 (1.2.90); FILE MERGED
2005/09/05 12:05:39 rt 1.2.90.1: #i54170# Change license header: remove SISSL
Diffstat (limited to 'scripting')
-rw-r--r-- | scripting/workben/installer/InstallationEvent.java | 40 | ||||
-rw-r--r-- | scripting/workben/installer/NavPanel.java | 222 |
2 files changed, 131 insertions, 131 deletions
diff --git a/scripting/workben/installer/InstallationEvent.java b/scripting/workben/installer/InstallationEvent.java index ea8661a8a977..d00dbe45a53e 100644 --- a/scripting/workben/installer/InstallationEvent.java +++ b/scripting/workben/installer/InstallationEvent.java @@ -1,22 +1,22 @@ package installer; -public class InstallationEvent
-{
- private Object source;
- private String message;
- InstallationEvent(Object source, String message)
- {
- this.source = source;
- this.message = message;
- }
-
- public Object getSource()
- {
- return source;
- }
-
- public String getMessage()
- {
- return message;
- }
-}
+public class InstallationEvent +{ + private Object source; + private String message; + InstallationEvent(Object source, String message) + { + this.source = source; + this.message = message; + } + + public Object getSource() + { + return source; + } + + public String getMessage() + { + return message; + } +} diff --git a/scripting/workben/installer/NavPanel.java b/scripting/workben/installer/NavPanel.java index 7101200a47c2..8c6cecc3042b 100644 --- a/scripting/workben/installer/NavPanel.java +++ b/scripting/workben/installer/NavPanel.java @@ -1,113 +1,113 @@ package installer; -import javax.swing.*;
-import java.awt.*;
-import java.awt.event.*;
-public class NavPanel extends JPanel implements ActionListener {
-
- NavPanel(InstallWizard wizard, boolean bBack, boolean bNext, boolean bCancel, String prev, String next) {
- setBackground(Color.white);
- setBorder(new javax.swing.border.EtchedBorder(javax.swing.border.EtchedBorder.LOWERED));
- this.wizard = wizard;
- this.next = next;
- this.prev = prev;
- navBack = new javax.swing.JButton("<< Back");
- navNext = new javax.swing.JButton("Next >>");
- navCancel = new javax.swing.JButton("Cancel");
- setLayout(new GridBagLayout());
-
- gridBagConstraints1 = new java.awt.GridBagConstraints();
- gridBagConstraints1.insets = new java.awt.Insets(1, 1, 1, 1);
- gridBagConstraints1.anchor = gridBagConstraints1.WEST;
-
- gridBagConstraints2 = new java.awt.GridBagConstraints();
- gridBagConstraints2.gridx = 2;
- gridBagConstraints2.gridy = 0;
-
- gridBagConstraints3 = new java.awt.GridBagConstraints();
- gridBagConstraints3.gridx = 6;
- gridBagConstraints3.gridy = 0;
-
- navNext.setEnabled(bNext);
- navBack.setEnabled(bBack);
- navCancel.setEnabled(bCancel);
- navNext.addActionListener(this);
- navBack.addActionListener(this);
- navCancel.addActionListener(this);
- add(navBack, gridBagConstraints1);
- add(navNext, gridBagConstraints2);
- add(navCancel, gridBagConstraints3);
- }
-
- public void enableNext(boolean bEnable) {
- navNext.setEnabled(bEnable);
- }
-
- public void enableBack(boolean bEnable) {
- navBack.setEnabled(bEnable);
- }
-
- public void enableCancel(boolean bEnable) {
- navCancel.setEnabled(bEnable);
- }
-
- public void enableIDE(boolean bEnable) {
- ideDetected = bEnable;
- }
-
- public void actionPerformed(ActionEvent ev) {
- if ((ev.getSource() == navNext) && (next.length() != 0)) {
- wizard.show(next);
- }
- if ((ev.getSource() == navBack) && (prev.length() != 0)) {
- wizard.show(prev);
- }
- if (ev.getSource() == navCancel) {
- if( ideDetected ) {
- wizard.show(InstallWizard.IDEWELCOME);
- }
- else {
- wizard.exitForm(null);
- }
- enableIDE(false);
- }
- }
-
- public void setNextListener(ActionListener listener) {
- navNext.addActionListener(listener);
- }
-
- public void setBackListener(ActionListener listener) {
- navBack.addActionListener(listener);
- }
-
- public void setCancelListener(ActionListener listener) {
- navCancel.addActionListener(listener);
- }
-
- public void removeNextListener(ActionListener listener)
- {
- navNext.removeActionListener(listener);
- }
-
- public void removeBackListener(ActionListener listener)
- {
- navBack.removeActionListener(listener);
- }
-
- public void removeCancelListener(ActionListener listener)
- {
- navCancel.removeActionListener(listener);
- }
-
- public JButton navBack;
- public JButton navNext;
- public JButton navCancel;
- private GridBagConstraints gridBagConstraints1;
- private GridBagConstraints gridBagConstraints2;
- private GridBagConstraints gridBagConstraints3;
- private InstallWizard wizard;
- private String next;
- private String prev;
- private boolean ideDetected = false;
-}
+import javax.swing.*; +import java.awt.*; +import java.awt.event.*; +public class NavPanel extends JPanel implements ActionListener { + + NavPanel(InstallWizard wizard, boolean bBack, boolean bNext, boolean bCancel, String prev, String next) { + setBackground(Color.white); + setBorder(new javax.swing.border.EtchedBorder(javax.swing.border.EtchedBorder.LOWERED)); + this.wizard = wizard; + this.next = next; + this.prev = prev; + navBack = new javax.swing.JButton("<< Back"); + navNext = new javax.swing.JButton("Next >>"); + navCancel = new javax.swing.JButton("Cancel"); + setLayout(new GridBagLayout()); + + gridBagConstraints1 = new java.awt.GridBagConstraints(); + gridBagConstraints1.insets = new java.awt.Insets(1, 1, 1, 1); + gridBagConstraints1.anchor = gridBagConstraints1.WEST; + + gridBagConstraints2 = new java.awt.GridBagConstraints(); + gridBagConstraints2.gridx = 2; + gridBagConstraints2.gridy = 0; + + gridBagConstraints3 = new java.awt.GridBagConstraints(); + gridBagConstraints3.gridx = 6; + gridBagConstraints3.gridy = 0; + + navNext.setEnabled(bNext); + navBack.setEnabled(bBack); + navCancel.setEnabled(bCancel); + navNext.addActionListener(this); + navBack.addActionListener(this); + navCancel.addActionListener(this); + add(navBack, gridBagConstraints1); + add(navNext, gridBagConstraints2); + add(navCancel, gridBagConstraints3); + } + + public void enableNext(boolean bEnable) { + navNext.setEnabled(bEnable); + } + + public void enableBack(boolean bEnable) { + navBack.setEnabled(bEnable); + } + + public void enableCancel(boolean bEnable) { + navCancel.setEnabled(bEnable); + } + + public void enableIDE(boolean bEnable) { + ideDetected = bEnable; + } + + public void actionPerformed(ActionEvent ev) { + if ((ev.getSource() == navNext) && (next.length() != 0)) { + wizard.show(next); + } + if ((ev.getSource() == navBack) && (prev.length() != 0)) { + wizard.show(prev); + } + if (ev.getSource() == navCancel) { + if( ideDetected ) { + wizard.show(InstallWizard.IDEWELCOME); + } + else { + wizard.exitForm(null); + } + enableIDE(false); + } + } + + public void setNextListener(ActionListener listener) { + navNext.addActionListener(listener); + } + + public void setBackListener(ActionListener listener) { + navBack.addActionListener(listener); + } + + public void setCancelListener(ActionListener listener) { + navCancel.addActionListener(listener); + } + + public void removeNextListener(ActionListener listener) + { + navNext.removeActionListener(listener); + } + + public void removeBackListener(ActionListener listener) + { + navBack.removeActionListener(listener); + } + + public void removeCancelListener(ActionListener listener) + { + navCancel.removeActionListener(listener); + } + + public JButton navBack; + public JButton navNext; + public JButton navCancel; + private GridBagConstraints gridBagConstraints1; + private GridBagConstraints gridBagConstraints2; + private GridBagConstraints gridBagConstraints3; + private InstallWizard wizard; + private String next; + private String prev; + private boolean ideDetected = false; +} |