rem
stringlengths 0
477k
| add
stringlengths 0
313k
| context
stringlengths 6
599k
|
---|---|---|
synchronized(singletonLock) { return singleton.doCreate(text, mnemonic); } | return SINGLETON.doCreate(text, mnemonic); | public static JMenuItem create(final String text, final Integer mnemonic) { synchronized(singletonLock) { return singleton.doCreate(text, mnemonic); } } |
public BinaryTypeConverterImpl(ValueFactory factory) { super(factory); } | public BinaryTypeConverterImpl() { super(); } | public BinaryTypeConverterImpl(ValueFactory factory) { super(factory); } |
public AbstractAtomicTypeConverterImpl(ValueFactory factory) { super(); valueFactory = factory; } | public AbstractAtomicTypeConverterImpl() { } | public AbstractAtomicTypeConverterImpl(ValueFactory factory) { super(); valueFactory = factory; } |
setBorder(new MultiLineBorder(new Color[] {BC_1, BC_2})); | public HistoryItems() { super("DocumentHistory", Color.WHITE); setBorder(new MultiLineBorder(new Color[] {BC_1, BC_2})); initComponents(); } |
|
javax.swing.JLabel infoJLabel; | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane historyListScrollPane; javax.swing.JLabel infoJLabel; infoJLabel = new javax.swing.JLabel(); historyListScrollPane = ScrollPaneFactory.create(); historyList = ListFactory.create(); setLayout(new java.awt.GridBagLayout()); infoJLabel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/HistoryInfoDisplay.png"))); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; add(infoJLabel, gridBagConstraints); historyListScrollPane.setBorder(null); historyListScrollPane.setViewportView(historyList); historyListScrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); historyModel = new DefaultListModel(); historyList.setCellRenderer(new ActiveCellRenderer()); // HEIGHT History List Cell 21 historyList.setFixedCellHeight(21); historyList.setLayoutOrientation(JList.VERTICAL); historyList.setModel(historyModel); historyList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); historyList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseReleased(java.awt.event.MouseEvent e) { historyListMouseReleased(e); } }); historyListScrollPane.setViewportView(historyList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 1; gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(2, 2, 0, 2); add(historyListScrollPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
|
infoJLabel = new javax.swing.JLabel(); | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane historyListScrollPane; javax.swing.JLabel infoJLabel; infoJLabel = new javax.swing.JLabel(); historyListScrollPane = ScrollPaneFactory.create(); historyList = ListFactory.create(); setLayout(new java.awt.GridBagLayout()); infoJLabel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/HistoryInfoDisplay.png"))); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; add(infoJLabel, gridBagConstraints); historyListScrollPane.setBorder(null); historyListScrollPane.setViewportView(historyList); historyListScrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); historyModel = new DefaultListModel(); historyList.setCellRenderer(new ActiveCellRenderer()); // HEIGHT History List Cell 21 historyList.setFixedCellHeight(21); historyList.setLayoutOrientation(JList.VERTICAL); historyList.setModel(historyModel); historyList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); historyList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseReleased(java.awt.event.MouseEvent e) { historyListMouseReleased(e); } }); historyListScrollPane.setViewportView(historyList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 1; gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(2, 2, 0, 2); add(historyListScrollPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
|
infoJLabel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/HistoryInfoDisplay.png"))); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; add(infoJLabel, gridBagConstraints); | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane historyListScrollPane; javax.swing.JLabel infoJLabel; infoJLabel = new javax.swing.JLabel(); historyListScrollPane = ScrollPaneFactory.create(); historyList = ListFactory.create(); setLayout(new java.awt.GridBagLayout()); infoJLabel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/HistoryInfoDisplay.png"))); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; add(infoJLabel, gridBagConstraints); historyListScrollPane.setBorder(null); historyListScrollPane.setViewportView(historyList); historyListScrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); historyModel = new DefaultListModel(); historyList.setCellRenderer(new ActiveCellRenderer()); // HEIGHT History List Cell 21 historyList.setFixedCellHeight(21); historyList.setLayoutOrientation(JList.VERTICAL); historyList.setModel(historyModel); historyList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); historyList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseReleased(java.awt.event.MouseEvent e) { historyListMouseReleased(e); } }); historyListScrollPane.setViewportView(historyList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 1; gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(2, 2, 0, 2); add(historyListScrollPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
|
gridBagConstraints.gridy = 1; | gridBagConstraints.gridy = 0; | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane historyListScrollPane; javax.swing.JLabel infoJLabel; infoJLabel = new javax.swing.JLabel(); historyListScrollPane = ScrollPaneFactory.create(); historyList = ListFactory.create(); setLayout(new java.awt.GridBagLayout()); infoJLabel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/HistoryInfoDisplay.png"))); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; add(infoJLabel, gridBagConstraints); historyListScrollPane.setBorder(null); historyListScrollPane.setViewportView(historyList); historyListScrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); historyModel = new DefaultListModel(); historyList.setCellRenderer(new ActiveCellRenderer()); // HEIGHT History List Cell 21 historyList.setFixedCellHeight(21); historyList.setLayoutOrientation(JList.VERTICAL); historyList.setModel(historyModel); historyList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); historyList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseReleased(java.awt.event.MouseEvent e) { historyListMouseReleased(e); } }); historyListScrollPane.setViewportView(historyList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 1; gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(2, 2, 0, 2); add(historyListScrollPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
gridBagConstraints.weightx = 1.0; | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane historyListScrollPane; javax.swing.JLabel infoJLabel; infoJLabel = new javax.swing.JLabel(); historyListScrollPane = ScrollPaneFactory.create(); historyList = ListFactory.create(); setLayout(new java.awt.GridBagLayout()); infoJLabel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/HistoryInfoDisplay.png"))); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; add(infoJLabel, gridBagConstraints); historyListScrollPane.setBorder(null); historyListScrollPane.setViewportView(historyList); historyListScrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); historyModel = new DefaultListModel(); historyList.setCellRenderer(new ActiveCellRenderer()); // HEIGHT History List Cell 21 historyList.setFixedCellHeight(21); historyList.setLayoutOrientation(JList.VERTICAL); historyList.setModel(historyModel); historyList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); historyList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseReleased(java.awt.event.MouseEvent e) { historyListMouseReleased(e); } }); historyListScrollPane.setViewportView(historyList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 1; gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(2, 2, 0, 2); add(historyListScrollPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
|
LogFactory logFactory, MessageFactory messageFactory) { this.application = application; this.settings = settings; this.messageStoreFactory = messageStoreFactory; this.logFactory = logFactory; this.messageFactory = messageFactory; sessionFactory = new SessionFactory(application, messageStoreFactory, logFactory); | MessageFactory messageFactory) { this(application, messageStoreFactory, settings, new ScreenLogFactory(settings), messageFactory); | protected AbstractSocketInitiator(Application application, MessageStoreFactory messageStoreFactory, SessionSettings settings, LogFactory logFactory, MessageFactory messageFactory) { this.application = application; this.settings = settings; this.messageStoreFactory = messageStoreFactory; this.logFactory = logFactory; this.messageFactory = messageFactory; sessionFactory = new SessionFactory(application, messageStoreFactory, logFactory); } |
this.sendVersionProvider = new SendVersionProvider(dModel, sessionModel, loggedInUser); | private ProviderFactory() { super(); final ModelFactory modelFactory = ModelFactory.getInstance(); this.artifactModel = modelFactory.getArtifactModel(getClass()); this.dModel = modelFactory.getDocumentModel(getClass()); this.logger = ModelLoggerFactory.getLogger(getClass()); this.loggedInUser = JabberIdBuilder.parseUsername(preferences.getUsername()); this.sessionModel = modelFactory.getSessionModel(getClass()); this.systemMessageModel = modelFactory.getSystemMessageModel(getClass()); this.historyProvider = new HistoryProvider(dModel); this.infoProvider = new InfoProvider(dModel); this.mainProvider = new MainProvider(artifactModel, dModel, systemMessageModel); this.manageContactsProvider = new ManageContactsProvider(sessionModel); this.sendArtifactProvider = new SendArtifactProvider(dModel, sessionModel, loggedInUser); } |
|
public HistoryProvider(final DocumentModel documentModel) { | public HistoryProvider(final JabberId loggedInUserId, final DocumentModel dModel, final SessionModel sModel) { | public HistoryProvider(final DocumentModel documentModel) { super(); this.documentProvider = new SingleContentProvider() { public Object getElement(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.get((Long) input); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.historyProvider = new FlatContentProvider() { public Object[] getElements(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.readHistory((Long) input).toArray(new HistoryItem[] {}); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.flatProviders = new FlatContentProvider[] { historyProvider }; this.singleProviders = new SingleContentProvider[] { documentProvider }; } |
try { return documentModel.get((Long) input); } | try { return dModel.get((Long) input); } | public HistoryProvider(final DocumentModel documentModel) { super(); this.documentProvider = new SingleContentProvider() { public Object getElement(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.get((Long) input); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.historyProvider = new FlatContentProvider() { public Object[] getElements(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.readHistory((Long) input).toArray(new HistoryItem[] {}); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.flatProviders = new FlatContentProvider[] { historyProvider }; this.singleProviders = new SingleContentProvider[] { documentProvider }; } |
try { return documentModel.readHistory((Long) input).toArray(new HistoryItem[] {}); } | try { return dModel.readHistory((Long) input).toArray(new HistoryItem[] {}); } | public HistoryProvider(final DocumentModel documentModel) { super(); this.documentProvider = new SingleContentProvider() { public Object getElement(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.get((Long) input); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.historyProvider = new FlatContentProvider() { public Object[] getElements(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.readHistory((Long) input).toArray(new HistoryItem[] {}); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.flatProviders = new FlatContentProvider[] { historyProvider }; this.singleProviders = new SingleContentProvider[] { documentProvider }; } |
this.flatProviders = new FlatContentProvider[] { historyProvider }; this.singleProviders = new SingleContentProvider[] { documentProvider }; | this.teamProvider = new FlatContentProvider() { public Object[] getElements(final Object input) { final Long documentId = (Long) input; final List<Contact> team; try { team = sModel.readArtifactContacts(documentId); } catch(final ParityException px) { throw new RuntimeException(px); } Contact contact; for(final Iterator<Contact> i = team.iterator(); i.hasNext();) { contact= i.next(); if(contact.getId().equals(loggedInUserId)) { i.remove(); } } return team.toArray(new Contact[] {}); } }; this.flatProviders = new FlatContentProvider[] {historyProvider, teamProvider}; this.singleProviders = new SingleContentProvider[] {documentProvider}; | public HistoryProvider(final DocumentModel documentModel) { super(); this.documentProvider = new SingleContentProvider() { public Object getElement(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.get((Long) input); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.historyProvider = new FlatContentProvider() { public Object[] getElements(final Object input) { Assert.assertNotNull( "The history provider requries java.lang.Long input.", input); Assert.assertOfType( "The history provider requries java.lang.Long input.", Long.class, input); try { return documentModel.readHistory((Long) input).toArray(new HistoryItem[] {}); } catch(final ParityException px) { throw new RuntimeException(px); } } }; this.flatProviders = new FlatContentProvider[] { historyProvider }; this.singleProviders = new SingleContentProvider[] { documentProvider }; } |
public InfoProvider(final DocumentModel dModel) { | public InfoProvider(final DocumentModel dModel, final SessionModel sModel) { | public InfoProvider(final DocumentModel dModel) { super(); this.countProvider = new SingleContentProvider() { public Object getElement(final Object input) { // TODO Create a statistics model to obtain and build // reports try { return dModel.list().size(); } catch(final ParityException px) { throw new RuntimeException(px); } } }; } |
this.singleProviders = new SingleContentProvider[] {countProvider, contactProvider}; | public InfoProvider(final DocumentModel dModel) { super(); this.countProvider = new SingleContentProvider() { public Object getElement(final Object input) { // TODO Create a statistics model to obtain and build // reports try { return dModel.list().size(); } catch(final ParityException px) { throw new RuntimeException(px); } } }; } |
|
XMPPMethod(final String name) { | public XMPPMethod(final String name) { | XMPPMethod(final String name) { super(); this.parameters = new LinkedList<Parameter>(); this.name = name; } |
final void setParameter(final String name, final UUID value) { parameters.add(new Parameter(name, UUID.class, value)); | public final void setParameter(final String name, final byte[] value) { parameters.add(new Parameter(name, byte[].class, value)); | final void setParameter(final String name, final UUID value) { parameters.add(new Parameter(name, UUID.class, value)); } |
reader.moveDown(); | private ActionWrapper readAction(final HierarchicalStreamReader reader, final UnmarshallingContext context) { reader.moveDown(); final DocumentAction action = DocumentAction.fromId(reader.getAttribute("id")); final DocumentActionData actionData; if(reader.hasMoreChildren()) { reader.moveDown(); actionData = new DocumentActionData(); while(reader.hasMoreChildren()) { readActionDataItem(actionData, reader, context); } reader.moveUp(); } else { actionData = null; } reader.moveUp(); return new ActionWrapper(action, actionData); } |
|
reader.moveUp(); | private ActionWrapper readAction(final HierarchicalStreamReader reader, final UnmarshallingContext context) { reader.moveDown(); final DocumentAction action = DocumentAction.fromId(reader.getAttribute("id")); final DocumentActionData actionData; if(reader.hasMoreChildren()) { reader.moveDown(); actionData = new DocumentActionData(); while(reader.hasMoreChildren()) { readActionDataItem(actionData, reader, context); } reader.moveUp(); } else { actionData = null; } reader.moveUp(); return new ActionWrapper(action, actionData); } |
|
else if(actionId.equals("send")) { return SEND; } | public static DocumentAction fromId(final String actionId) { if(actionId.equals("create")) { return CREATE; } else if(actionId.equals("receive")) { return RECEIVE; } else { throw new IllegalArgumentException( "Unrecognized document action: " + actionId); } } |
|
if (XMPPUncheckedException.class.isAssignableFrom(t.getClass())) { return (XMPPUncheckedException) t; } else if (Assertion.class.isAssignableFrom(t.getClass())) { final String errorId = new ErrorHelper().getErrorId(t); logger.logError(t, errorId); return (Assertion) t; } else { final String errorId = new ErrorHelper().getErrorId(t); logger.logError(t, errorId); return XMPPErrorTranslator.translateUnchecked(xmppCore, errorId, t); } | return xmppCore.translateError(t); | protected RuntimeException translateError(final Throwable t) { if (XMPPUncheckedException.class.isAssignableFrom(t.getClass())) { return (XMPPUncheckedException) t; } else if (Assertion.class.isAssignableFrom(t.getClass())) { final String errorId = new ErrorHelper().getErrorId(t); logger.logError(t, errorId); return (Assertion) t; } else { final String errorId = new ErrorHelper().getErrorId(t); logger.logError(t, errorId); return XMPPErrorTranslator.translateUnchecked(xmppCore, errorId, t); } } |
WorkspaceModel.getModel(environment).getWorkspace( | workspaceModel.getWorkspace( | private OpheliaTestUser(final Environment environment, final String username) { super(); this.credentials = new Credentials(); this.credentials.setPassword(PASSWORD); this.credentials.setUsername(username); this.environment = environment; this.workspace = WorkspaceModel.getModel(environment).getWorkspace( new File(OpheliaTestCase.SESSION.getOutputDirectory(), "TEST." + username)); this.workspace.getPreferences().setUsername(username); processOfflineQueue(); initialize(); } |
this.workspace.getPreferences().setUsername(username); | private OpheliaTestUser(final Environment environment, final String username) { super(); this.credentials = new Credentials(); this.credentials.setPassword(PASSWORD); this.credentials.setUsername(username); this.environment = environment; this.workspace = WorkspaceModel.getModel(environment).getWorkspace( new File(OpheliaTestCase.SESSION.getOutputDirectory(), "TEST." + username)); this.workspace.getPreferences().setUsername(username); processOfflineQueue(); initialize(); } |
|
SessionModel.getModel(environment, workspace).login(new DefaultLoginMonitor() { @Override public Boolean confirmSynchronize() { return Boolean.TRUE; } }, credentials); try { ContactModel.getModel(environment, workspace).download(); setId(ProfileModel.getModel(environment, workspace).read().getId()); } finally { SessionModel.getModel(environment, workspace).logout(); | final WorkspaceModel workspaceModel = WorkspaceModel.getModel(environment); if (!workspaceModel.isInitialized(workspace)) { workspaceModel.initialize(workspace, new LoginMonitor() { public Boolean confirmSynchronize() { return Boolean.TRUE; } public void notifyInvalidCredentials( final Credentials credentials) { } }, credentials); | private void initialize() { SessionModel.getModel(environment, workspace).login(new DefaultLoginMonitor() { @Override public Boolean confirmSynchronize() { return Boolean.TRUE; } }, credentials); try { ContactModel.getModel(environment, workspace).download(); setId(ProfileModel.getModel(environment, workspace).read().getId()); } finally { SessionModel.getModel(environment, workspace).logout(); } setId(JabberIdBuilder.parseUsername(credentials.getUsername())); } |
setId(JabberIdBuilder.parseUsername(credentials.getUsername())); | setId(JabberIdBuilder.build( credentials.getUsername(), environment.getXMPPService())); SessionModel.getModel(environment, workspace).logout(); | private void initialize() { SessionModel.getModel(environment, workspace).login(new DefaultLoginMonitor() { @Override public Boolean confirmSynchronize() { return Boolean.TRUE; } }, credentials); try { ContactModel.getModel(environment, workspace).download(); setId(ProfileModel.getModel(environment, workspace).read().getId()); } finally { SessionModel.getModel(environment, workspace).logout(); } setId(JabberIdBuilder.parseUsername(credentials.getUsername())); } |
setPopupDelegate(model.getPopupDelegate()); | setSortByDelegate(model); | public ContainerTabAvatar() { super(AvatarId.TAB_CONTAINER, new ContainerTabModel()); model.setLocalization(getLocalization()); model.setSession(getSession()); setPopupDelegate(model.getPopupDelegate()); } |
this.containerPanels = new ArrayList<TabPanel>(); | this.filteredPanels = new ArrayList<TabPanel>(); | ContainerTabModel() { super(); this.actionDelegate = new ContainerTabActionDelegate(this); this.browser = getBrowser(); this.containerIdLookup = new HashMap<Long, Long>(); this.containerPanels = new ArrayList<TabPanel>(); this.expandedState = new HashMap<TabPanel, Boolean>(); this.listModel = new DefaultListModel(); this.popupDelegate = new ContainerTabPopupDelegate(this); this.visiblePanels = new ArrayList<TabPanel>(); } |
this.searchResults = new ArrayList<Long>(); | ContainerTabModel() { super(); this.actionDelegate = new ContainerTabActionDelegate(this); this.browser = getBrowser(); this.containerIdLookup = new HashMap<Long, Long>(); this.containerPanels = new ArrayList<TabPanel>(); this.expandedState = new HashMap<TabPanel, Boolean>(); this.listModel = new DefaultListModel(); this.popupDelegate = new ContainerTabPopupDelegate(this); this.visiblePanels = new ArrayList<TabPanel>(); } |
|
public double getDouble(SessionID sessionID, String key) throws ConfigError, FieldConvertError { try { return Double.parseDouble(getString(sessionID, key)); } catch (NumberFormatException e) { throw new FieldConvertError(e.getMessage()); } | public double getDouble(String key) throws ConfigError, FieldConvertError { return getDouble(DEFAULT_SESSION_ID, key); | public double getDouble(SessionID sessionID, String key) throws ConfigError, FieldConvertError { try { return Double.parseDouble(getString(sessionID, key)); } catch (NumberFormatException e) { throw new FieldConvertError(e.getMessage()); } } |
public static String getExtension(String fileName) { if(-1 != fileName.indexOf(Separator.Period.toString())) return fileName.substring( fileName.lastIndexOf(Separator.Period.toString())); return fileName; | public static String getExtension(final File file) { if(null == file) { throw new NullPointerException(); } return FileUtil.getExtension(file.getName()); | public static String getExtension(String fileName) { if(-1 != fileName.indexOf(Separator.Period.toString())) return fileName.substring( fileName.lastIndexOf(Separator.Period.toString())); return fileName; } |
public static String getName(final String fileName) { if(-1 != fileName.indexOf(Separator.Period.toString())) return fileName.substring( 0, fileName.lastIndexOf(Separator.Period.toString())); return fileName; | public static String getName(final File file) { if(null == file) { throw new NullPointerException(); } return getName(file.getName()); | public static String getName(final String fileName) { if(-1 != fileName.indexOf(Separator.Period.toString())) return fileName.substring( 0, fileName.lastIndexOf(Separator.Period.toString())); return fileName; } |
public void close(final UUID documentUniqueId) throws ParityException { synchronized(getImplLock()) { getImpl().close(documentUniqueId); } | public void close(final UUID documentUniqueId, final JabberId closedBy) throws ParityException { synchronized(getImplLock()) { getImpl().close(documentUniqueId, closedBy); } | public void close(final UUID documentUniqueId) throws ParityException { synchronized(getImplLock()) { getImpl().close(documentUniqueId); } } |
html.append("<h2>VelocityServlet : Error processing the template</h2>"); | html.append("<h2>VelocityViewServlet : Error processing the template</h2>"); | protected void error(HttpServletRequest request, HttpServletResponse response, Exception cause) throws ServletException, IOException { StringBuffer html = new StringBuffer(); html.append("<html>"); html.append("<title>Error</title>"); html.append("<body bgcolor=\"#ffffff\">"); html.append("<h2>VelocityServlet : Error processing the template</h2>"); html.append("<pre>"); String why = cause.getMessage(); if (why != null && why.trim().length() > 0) { html.append(why); html.append("<br>"); } StringWriter sw = new StringWriter(); cause.printStackTrace(new PrintWriter(sw)); html.append(sw.toString()); html.append("</pre>"); html.append("</body>"); html.append("</html>"); response.getOutputStream().print(html.toString()); } |
javax.swing.JButton closeJButton; | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
|
javax.swing.JButton searchJButton; | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
|
closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
|
searchJButton = ButtonFactory.create(getString("SearchButton")); | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
|
} }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
|
searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); | invitationJLabel.setText("!Email Invitation!"); | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
.add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) | .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 281, Short.MAX_VALUE) | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
.add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) | .add(emailJLabel) .add(invitationJLabel)) | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
.add(closeJButton) .add(previewJButton) .add(sendJButton)))) | .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 196, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(sendJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(previewJButton)) .add(layout.createSequentialGroup() .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 196, Short.MAX_VALUE) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED))) | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
.add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) | .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
.add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) | .add(invitationJLabel) .add(123, 123, 123)) | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
.add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) | .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED))) | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
.add(closeJButton) .add(manageJButton) .add(searchJButton)) | .add(previewJButton) .add(sendJButton)) | private void initComponents() { javax.swing.JButton closeJButton; javax.swing.JLabel eaJLabel; javax.swing.JLabel emailJLabel; javax.swing.JLabel invitationJLabel; javax.swing.JScrollPane jScrollPane1; javax.swing.JButton manageJButton; javax.swing.JButton previewJButton; javax.swing.JButton searchJButton; eaJLabel = LabelFactory.create(getString("EmbeddedAssistance")); emailJLabel = LabelFactory.create(getString("EmailLabel")); emailJTextField = TextFactory.create(); sendJButton = ButtonFactory.create(getString("SendButton")); closeJButton = ButtonFactory.create(getString("CloseButton")); manageJButton = ButtonFactory.create(getString("ManageButton")); jScrollPane1 = new javax.swing.JScrollPane(); invitationJTextArea = TextFactory.createArea(); invitationJLabel = LabelFactory.create(getString("InvitationLabel")); searchJButton = ButtonFactory.create(getString("SearchButton")); previewJButton = ButtonFactory.create(getString("PreviewButton")); emailJTextField.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { emailJTextFieldChangedUpdate(e); } }); sendJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } }); closeJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeJButtonActionPerformed(e); } }); manageJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } }); invitationJTextArea.setColumns(20); invitationJTextArea.setRows(5); invitationJTextArea.getDocument().addDocumentListener(new DocumentListener() { public void insertUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaInsertUpdate(e); } public void removeUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaRemoveUpdate(e); } public void changedUpdate(final javax.swing.event.DocumentEvent e) { invitationJTextAreaChangedUpdate(e); } }); jScrollPane1.setViewportView(invitationJTextArea); searchJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { searchJButtonActionPerformed(e); } }); previewJButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { previewJButtonActionPerformed(e); } }); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(eaJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 372, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(emailJLabel) .add(invitationJLabel)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE) .add(emailJTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE))) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() .add(searchJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(manageJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(closeJButton) .add(previewJButton) .add(sendJButton)))) .addContainerGap()) ); layout.setVerticalGroup( layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .addContainerGap() .add(eaJLabel) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(layout.createSequentialGroup() .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(emailJLabel) .add(emailJTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(layout.createSequentialGroup() .add(invitationJLabel) .add(117, 117, 117)) .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE))) .add(layout.createSequentialGroup() .add(previewJButton) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(sendJButton))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(closeJButton) .add(manageJButton) .add(searchJButton)) .addContainerGap()) ); }// </editor-fold>//GEN-END:initComponents |
manageJButtonActionPerformed(e); | previewJButtonActionPerformed(e); | public void actionPerformed(java.awt.event.ActionEvent e) { manageJButtonActionPerformed(e); } |
if(!jabberIds.contains(auditEvent.getCreatedBy())) jabberIds.add(auditEvent.getCreatedBy()); break; case REQUEST_KEY: if(!jabberIds.contains(((RequestKeyEvent) auditEvent).getRequestedBy())) jabberIds.add(((RequestKeyEvent) auditEvent).getRequestedBy()); if(!jabberIds.contains(((RequestKeyEvent) auditEvent).getRequestedFrom())) jabberIds.add(((RequestKeyEvent) auditEvent).getRequestedFrom()); | private Map<JabberId, User> buildAuditUserMap( final Iterable<AuditEvent> auditEvents) throws ParityException { final List<JabberId> jabberIds = new LinkedList<JabberId>(); for(final AuditEvent auditEvent : auditEvents) { switch(auditEvent.getType()) { case CLOSE: case CREATE: if(!jabberIds.contains(auditEvent.getCreatedBy())) jabberIds.add(auditEvent.getCreatedBy()); break; case RECEIVE: if(!jabberIds.contains(((ReceiveEvent) auditEvent).getReceivedFrom())) jabberIds.add(((ReceiveEvent) auditEvent).getReceivedFrom()); if(!jabberIds.contains(auditEvent.getCreatedBy())) jabberIds.add(auditEvent.getCreatedBy()); break; case RECEIVE_KEY: if(!jabberIds.contains(((ReceiveKeyEvent) auditEvent).getReceivedFrom())) jabberIds.add(((ReceiveKeyEvent) auditEvent).getReceivedFrom()); if(!jabberIds.contains(auditEvent.getCreatedBy())) jabberIds.add(auditEvent.getCreatedBy()); break; case SEND: for(final JabberId sentTo : ((SendEvent) auditEvent).getSentTo()) { if(!jabberIds.contains(sentTo)) jabberIds.add(sentTo); } if(!jabberIds.contains(auditEvent.getCreatedBy())) jabberIds.add(auditEvent.getCreatedBy()); break; case SEND_KEY: if(!jabberIds.contains(((SendKeyEvent) auditEvent).getSentTo())) jabberIds.add(((SendKeyEvent) auditEvent).getSentTo()); if(!jabberIds.contains(auditEvent.getCreatedBy())) jabberIds.add(auditEvent.getCreatedBy()); break; default: Assert.assertUnreachable(""); } } final InternalSessionModel iSModel = getInternalSessionModel(); final List<User> users = iSModel.readUsers(jabberIds); final Map<JabberId, User> userMap = new LinkedHashMap<JabberId, User>(); for(final User user : users) { userMap.put(user.getId(), user); } return userMap; } |
|
logger.info("close(Long)"); | logger.info("[LMODEL] [DOCUMENT] [CLOSE]"); | void close(final Long documentId) throws ParityException { logger.info("close(Long)"); logger.debug(documentId); assertLoggedInUserIsKeyHolder(documentId); try { // close the document final Document document = get(documentId); assertStateTransition(document.getState(), ArtifactState.CLOSED); documentIO.updateState(document.getId(), ArtifactState.CLOSED); // lock the document lock(documentId); // send the closeure to the server final InternalSessionModel iSModel = getInternalSessionModel(); iSModel.sendClose(documentId); // audit the closeure final Document d = get(documentId); auditor.close(d.getId(), JabberIdBuilder.parseUsername(preferences.getUsername()), d.getUpdatedOn()); // fire event notifyUpdate_objectClosed(d); } catch(final RuntimeException rx) { logger.error("Cannot close document: " + documentId, rx); throw ParityErrorTranslator.translate(rx); } } |
auditor.close(d.getId(), JabberIdBuilder.parseUsername(preferences.getUsername()), d.getUpdatedOn()); | auditor.close(d.getId(), currentUserId(), d.getUpdatedOn(), currentUserId()); | void close(final Long documentId) throws ParityException { logger.info("close(Long)"); logger.debug(documentId); assertLoggedInUserIsKeyHolder(documentId); try { // close the document final Document document = get(documentId); assertStateTransition(document.getState(), ArtifactState.CLOSED); documentIO.updateState(document.getId(), ArtifactState.CLOSED); // lock the document lock(documentId); // send the closeure to the server final InternalSessionModel iSModel = getInternalSessionModel(); iSModel.sendClose(documentId); // audit the closeure final Document d = get(documentId); auditor.close(d.getId(), JabberIdBuilder.parseUsername(preferences.getUsername()), d.getUpdatedOn()); // fire event notifyUpdate_objectClosed(d); } catch(final RuntimeException rx) { logger.error("Cannot close document: " + documentId, rx); throw ParityErrorTranslator.translate(rx); } } |
auditor.create(d.getId(), JabberIdBuilder.parseUsername(preferences.getUsername()), d.getCreatedOn()); | auditor.create(d.getId(), currentUserId(), d.getCreatedOn()); | Document create(final String name, final String description, final File file) throws ParityException { logger.info("create(Project,String,String,File)"); logger.debug(name); logger.debug(description); logger.debug(file); assertCanCreateArtifacts(); assertIsSessionValid(); Assert.assertTrue( // TODO Centralize business rules about document creation. "File \"" + file.getAbsolutePath() + "\" does not exist.", file.exists()); Assert.assertTrue( "create(Project,String,String,File)", (file.length() <= IParityModelConstants.FILE_SIZE_UPPER_BOUNDS)); try { final Calendar now = currentDateTime(); final Document document = new Document(preferences.getUsername(), now, description, Collections.<ArtifactFlag>emptyList(), UUIDGenerator.nextUUID(), name, preferences.getUsername(), now); document.setState(ArtifactState.ACTIVE); final byte[] contentBytes = FileUtil.readBytes(file); final DocumentContent content = new DocumentContent(); content.setContent(contentBytes); content.setChecksum(MD5Util.md5Hex(contentBytes)); content.setDocumentId(document.getId()); // send a creation packet final InternalSessionModel iSessionModel = SessionModel.getInternalModel(getContext()); iSessionModel.sendCreate(document); // create the document documentIO.create(document, content); // create the local file final LocalFile localFile = getLocalFile(document); localFile.write(contentBytes); // create a version createVersion(document.getId()); // flag the document as having been seen. final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.applyFlagKey(document.getId()); iAModel.applyFlagSeen(document.getId()); // fire a creation event final Document d = get(document.getId()); notifyCreation_objectCreated(d); // audit the creation auditor.create(d.getId(), JabberIdBuilder.parseUsername(preferences.getUsername()), d.getCreatedOn()); return d; } catch(IOException iox) { logger.error("createDocument(Document)", iox); throw ParityErrorTranslator.translate(iox); } catch(RuntimeException rx) { logger.error("createDocument(Document)", rx); throw ParityErrorTranslator.translate(rx); } } |
if(ArtifactState.CLOSED != document.getState()) assertLoggedInUserIsNotKeyHolder(documentId); | void delete(final Long documentId) throws ParityException { logger.info("delete(Long)"); logger.debug(documentId); try { final Document document = get(documentId); assertStateTransition(document.getState(), ArtifactState.DELETED); // delete the document remotely final InternalSessionModel iSModel = getInternalSessionModel(); iSModel.sendDelete(documentId); // delete the audit info final InternalAuditModel iAModel = getInternalAuditModel(); iAModel.delete(documentId); // delete the versions locally final Collection<DocumentVersion> versions = listVersions(documentId); for(final DocumentVersion version : versions) { getLocalFile(document, version).delete(); documentIO.deleteVersion(documentId, version.getVersionId()); } // delete the document locally final LocalFile localFile = getLocalFile(document); localFile.delete(); localFile.deleteParent(); documentIO.delete(documentId); // notify notifyUpdate_objectDeleted(document); } catch(RuntimeException rx) { logger.error("delete(UUID)", rx); throw ParityErrorTranslator.translate(rx); } } |
|
auditor.recieve(document.getId(), xmppDocument.getVersionId(), receivedFromJabberId, JabberIdBuilder.parseUsername(preferences.getUsername()), currentDateTime()); | final Document d = get(document.getId()); auditor.recieve(d.getId(), xmppDocument.getVersionId(), receivedFromJabberId, currentUserId(), currentDateTime()); notifyUpdate_objectReceived(d); | void receive(final XMPPDocument xmppDocument) throws ParityException { logger.info("receiveDocument(XMPPDocument)"); logger.debug(xmppDocument); try { final JabberId receivedFromJabberId = JabberIdBuilder.parseUsername(xmppDocument.getReceivedFrom()); Document document = get(xmppDocument.getUniqueId()); logger.debug(document); if(null == document) { document = receiveCreate(xmppDocument); } else { final DocumentVersion version = getVersion(document.getId(), xmppDocument.getVersionId()); // i have this version. wtf? biotch if(null == version) { receiveUpdate(xmppDocument, document); } } // audit the receiving auditor.recieve(document.getId(), xmppDocument.getVersionId(), receivedFromJabberId, JabberIdBuilder.parseUsername(preferences.getUsername()), currentDateTime()); } catch(IOException iox) { logger.error("receiveDocument(XMPPDocument)", iox); throw ParityErrorTranslator.translate(iox); } catch(RuntimeException rx) { logger.error("receiveDocument(XMPPDocument)", rx); throw ParityErrorTranslator.translate(rx); } } |
if(iSModel.isLoggedInUserKeyHolder(document.getId())) { final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.applyFlagKey(document.getId()); | if(!iSModel.isLoggedInUserKeyHolder(document.getId())) { lock(document.getId()); | private void receiveUpdate(final XMPPDocument xmppDocument, final Document document) throws FileNotFoundException, IOException, ParityException { final DocumentVersion version = new DocumentVersion(); version.setArtifactId(document.getId()); version.setArtifactType(document.getType()); version.setArtifactUniqueId(document.getUniqueId()); version.setCreatedBy(xmppDocument.getCreatedBy()); version.setCreatedOn(xmppDocument.getCreatedOn()); version.setName(document.getName()); version.setUpdatedBy(xmppDocument.getUpdatedBy()); version.setUpdatedOn(xmppDocument.getUpdatedOn()); version.setVersionId(xmppDocument.getVersionId()); final DocumentContent content = new DocumentContent(); content.setChecksum(MD5Util.md5Hex(xmppDocument.getContent())); content.setContent(xmppDocument.getContent()); content.setDocumentId(version.getArtifactId()); final DocumentVersionContent versionContent = new DocumentVersionContent(); versionContent.setDocumentContent(content); versionContent.setDocumentId(version.getArtifactId()); versionContent.setVersionId(version.getVersionId()); insertVersion(version.getArtifactId(), version, versionContent); if(isLatestLocalVersion(version)) { document.setUpdatedBy(xmppDocument.getUpdatedBy()); document.setUpdatedOn(xmppDocument.getUpdatedOn()); // update the db documentIO.update(document); documentIO.updateContent(content); // update the local file final LocalFile localFile = getLocalFile(document); localFile.delete(); localFile.write(content.getContent()); } // if key holder: apply flag key // if not key holder: lock final InternalSessionModel iSModel = getInternalSessionModel(); if(iSModel.isLoggedInUserKeyHolder(document.getId())) { final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.applyFlagKey(document.getId()); } else { lock(document.getId()); } // remove flag seen final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.removeFlagSeen(document.getId()); // notify notifyUpdate_objectReceived(document); } |
else { lock(document.getId()); } | private void receiveUpdate(final XMPPDocument xmppDocument, final Document document) throws FileNotFoundException, IOException, ParityException { final DocumentVersion version = new DocumentVersion(); version.setArtifactId(document.getId()); version.setArtifactType(document.getType()); version.setArtifactUniqueId(document.getUniqueId()); version.setCreatedBy(xmppDocument.getCreatedBy()); version.setCreatedOn(xmppDocument.getCreatedOn()); version.setName(document.getName()); version.setUpdatedBy(xmppDocument.getUpdatedBy()); version.setUpdatedOn(xmppDocument.getUpdatedOn()); version.setVersionId(xmppDocument.getVersionId()); final DocumentContent content = new DocumentContent(); content.setChecksum(MD5Util.md5Hex(xmppDocument.getContent())); content.setContent(xmppDocument.getContent()); content.setDocumentId(version.getArtifactId()); final DocumentVersionContent versionContent = new DocumentVersionContent(); versionContent.setDocumentContent(content); versionContent.setDocumentId(version.getArtifactId()); versionContent.setVersionId(version.getVersionId()); insertVersion(version.getArtifactId(), version, versionContent); if(isLatestLocalVersion(version)) { document.setUpdatedBy(xmppDocument.getUpdatedBy()); document.setUpdatedOn(xmppDocument.getUpdatedOn()); // update the db documentIO.update(document); documentIO.updateContent(content); // update the local file final LocalFile localFile = getLocalFile(document); localFile.delete(); localFile.write(content.getContent()); } // if key holder: apply flag key // if not key holder: lock final InternalSessionModel iSModel = getInternalSessionModel(); if(iSModel.isLoggedInUserKeyHolder(document.getId())) { final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.applyFlagKey(document.getId()); } else { lock(document.getId()); } // remove flag seen final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.removeFlagSeen(document.getId()); // notify notifyUpdate_objectReceived(document); } |
|
notifyUpdate_objectReceived(document); | private void receiveUpdate(final XMPPDocument xmppDocument, final Document document) throws FileNotFoundException, IOException, ParityException { final DocumentVersion version = new DocumentVersion(); version.setArtifactId(document.getId()); version.setArtifactType(document.getType()); version.setArtifactUniqueId(document.getUniqueId()); version.setCreatedBy(xmppDocument.getCreatedBy()); version.setCreatedOn(xmppDocument.getCreatedOn()); version.setName(document.getName()); version.setUpdatedBy(xmppDocument.getUpdatedBy()); version.setUpdatedOn(xmppDocument.getUpdatedOn()); version.setVersionId(xmppDocument.getVersionId()); final DocumentContent content = new DocumentContent(); content.setChecksum(MD5Util.md5Hex(xmppDocument.getContent())); content.setContent(xmppDocument.getContent()); content.setDocumentId(version.getArtifactId()); final DocumentVersionContent versionContent = new DocumentVersionContent(); versionContent.setDocumentContent(content); versionContent.setDocumentId(version.getArtifactId()); versionContent.setVersionId(version.getVersionId()); insertVersion(version.getArtifactId(), version, versionContent); if(isLatestLocalVersion(version)) { document.setUpdatedBy(xmppDocument.getUpdatedBy()); document.setUpdatedOn(xmppDocument.getUpdatedOn()); // update the db documentIO.update(document); documentIO.updateContent(content); // update the local file final LocalFile localFile = getLocalFile(document); localFile.delete(); localFile.write(content.getContent()); } // if key holder: apply flag key // if not key holder: lock final InternalSessionModel iSModel = getInternalSessionModel(); if(iSModel.isLoggedInUserKeyHolder(document.getId())) { final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.applyFlagKey(document.getId()); } else { lock(document.getId()); } // remove flag seen final InternalArtifactModel iAModel = getInternalArtifactModel(); iAModel.removeFlagSeen(document.getId()); // notify notifyUpdate_objectReceived(document); } |
|
smackVCard.setEmailHome(vCard.getEmail()); | smackVCard.setEmailWork(vCard.getEmail()); | void updateVCard(final JabberId jabberId, final UserVCard vCard) throws SmackException { logger.info("[LMODEL] [XMPP USER] [UPDATE VCARD]"); logger.debug(jabberId); logger.debug(vCard); try { final VCard smackVCard = new VCard(); smackVCard.load(xmppCore.getConnection(), jabberId.getQualifiedUsername()); smackVCard.setFirstName(vCard.getFirstName()); if(vCard.isSetMiddleName()) smackVCard.setMiddleName(vCard.getMiddleName()); smackVCard.setLastName(vCard.getLastName()); smackVCard.setEmailHome(vCard.getEmail()); smackVCard.setOrganization(vCard.getOrganization()); smackVCard.save(xmppCore.getConnection()); } catch(final XMPPException xmppx) { logger.error("", xmppx); throw XMPPErrorTranslator.translate(xmppx); } } |
applyColorChange(jLabel); | private JLabel doCreateLink(final String text, final Font font) { final JLabel jLabel = doCreate(text, font, LINK_FOREGROUND); applyHandCursor(jLabel); return jLabel; } |
|
protected ComponentFactory() { super(); } | protected ComponentFactory() { super(); this.logger = LoggerFactory.getLogger(getClass()); } | protected ComponentFactory() { super(); } |
final Cursor handCursor = new Cursor(Cursor.HAND_CURSOR); | protected void applyHandCursor(final Component component) { component.addMouseListener(new MouseAdapter() { final Cursor originalCursor = component.getCursor(); final Cursor handCursor = new Cursor(Cursor.HAND_CURSOR); public void mouseEntered(final MouseEvent e) { component.setCursor(handCursor); } public void mouseExited(final MouseEvent e) { component.setCursor(originalCursor); } }); } |
|
private XMPPDocument(final byte[] content, final String createdBy, final Calendar createdOn, final String description, final String name, final UUID uniqueId, final String updatedBy, final Calendar updatedOn, final Long versionId) { super(); this.content = new byte[content.length]; System.arraycopy(content, 0, this.content, 0, content.length); this.createdBy = createdBy; this.createdOn = createdOn; this.description = description; this.name = name; this.uniqueId = uniqueId; this.updatedBy = updatedBy; this.updatedOn = updatedOn; this.versionId = versionId; } | public XMPPDocument() { super(); } | private XMPPDocument(final byte[] content, final String createdBy, final Calendar createdOn, final String description, final String name, final UUID uniqueId, final String updatedBy, final Calendar updatedOn, final Long versionId) { super(); this.content = new byte[content.length]; System.arraycopy(content, 0, this.content, 0, content.length); this.createdBy = createdBy; this.createdOn = createdOn; this.description = description; this.name = name; this.uniqueId = uniqueId; this.updatedBy = updatedBy; this.updatedOn = updatedOn; this.versionId = versionId; } |
final String description, final String name, final UUID uniqueId, | final String description, final String name, final String receivedFrom, final UUID uniqueId, | public static XMPPDocument create(final byte[] content, final String createdBy, final Calendar createdOn, final String description, final String name, final UUID uniqueId, final String updatedBy, final Calendar updatedOn, final Long versionId) { return new XMPPDocument(content, createdBy, createdOn, description, name, uniqueId, updatedBy, updatedOn, versionId); } |
name, uniqueId, updatedBy, updatedOn, versionId); | name, receivedFrom, uniqueId, updatedBy, updatedOn, versionId); | public static XMPPDocument create(final byte[] content, final String createdBy, final Calendar createdOn, final String description, final String name, final UUID uniqueId, final String updatedBy, final Calendar updatedOn, final Long versionId) { return new XMPPDocument(content, createdBy, createdOn, description, name, uniqueId, updatedBy, updatedOn, versionId); } |
if (e.isPopupTrigger()) jList.putClientProperty(CPK_IS_POPUP_TRIGGER, Boolean.TRUE); else jList.putClientProperty(CPK_IS_POPUP_TRIGGER, Boolean.FALSE); | if (e.isPopupTrigger()) { jList.setSelectedIndex(jList.locationToIndex(e.getPoint())); popupDelegate.initialize((Component) e.getSource(), e.getX(), e.getY()); ((DefaultVersionCell) jList.getSelectedValue()).showPopup(); } | private void jListMousePressed(final JList jList, final java.awt.event.MouseEvent e) { logger.logApiId(); logger.logVariable("e", e); if (e.isPopupTrigger()) jList.putClientProperty(CPK_IS_POPUP_TRIGGER, Boolean.TRUE); else jList.putClientProperty(CPK_IS_POPUP_TRIGGER, Boolean.FALSE); } |
final Boolean isPopupTrigger = (Boolean) jList.getClientProperty(CPK_IS_POPUP_TRIGGER); if (null != isPopupTrigger && isPopupTrigger.booleanValue()) { | if (e.isPopupTrigger()) { | private void jListMouseReleased(final JList jList, final java.awt.event.MouseEvent e) { logger.logApiId(); logger.logVariable("e", e); final Boolean isPopupTrigger = (Boolean) jList.getClientProperty(CPK_IS_POPUP_TRIGGER); if (null != isPopupTrigger && isPopupTrigger.booleanValue()) { jList.setSelectedIndex(jList.locationToIndex(e.getPoint())); popupDelegate.initialize((Component) e.getSource(), e.getX(), e.getY()); ((DefaultVersionCell) jList.getSelectedValue()).showPopup(); } } |
public Boolean isKeyHolder() { return ArtifactUtil.isKeyHolder(getId()); } | public Boolean isKeyHolder() { return keyHolder; } | public Boolean isKeyHolder() { return ArtifactUtil.isKeyHolder(getId()); } |
deleteData.set(DeleteDraft.DataKey.CONTAINER_ID, getId()); | deleteDraftData.set(DeleteDraft.DataKey.CONTAINER_ID, getId()); | void show(final Component invoker, final MouseEvent e) { final JPopupMenu jPopupMenu = MenuFactory.createPopup(); if (!isDraft()) { final Data createDraftData = new Data(1); createDraftData.set(CreateDraft.DataKey.CONTAINER_ID, getId()); jPopupMenu.add(popupItemFactory.createPopupItem(ActionId.CONTAINER_CREATE_DRAFT, createDraftData)); } final Data deleteData = new Data(1); deleteData.set(Delete.DataKey.CONTAINER_ID, getId()); jPopupMenu.add(popupItemFactory.createPopupItem(ActionId.CONTAINER_DELETE, deleteData)); // include the container's id and unique id in the menu if(e.isShiftDown()) { final Clipboard systemClipboard = Toolkit.getDefaultToolkit().getSystemClipboard(); final ActionListener debugActionListener = new ActionListener() { public void actionPerformed(final ActionEvent e) { final StringSelection stringSelection = new StringSelection(((JComponent) e.getSource()).getClientProperty("COPY_ME").toString()); systemClipboard.setContents(stringSelection, null); } }; final JMenuItem idJMenuItem = new JMenuItem("Id - " + getId()); idJMenuItem.putClientProperty("COPY_ME", getId()); idJMenuItem.addActionListener(debugActionListener); final JMenuItem uidJMenuItem = new JMenuItem("Unique id - " + getUniqueId()); uidJMenuItem.putClientProperty("COPY_ME", getUniqueId()); uidJMenuItem.addActionListener(debugActionListener); jPopupMenu.addSeparator(); jPopupMenu.add(idJMenuItem); jPopupMenu.add(uidJMenuItem); } final Data addDocumentData = new Data(1); addDocumentData.set(AddDocument.DataKey.CONTAINER_ID, getId()); addDocumentData.set(AddDocument.DataKey.FILES, new File[0]); jPopupMenu.add(popupItemFactory.createPopupItem(ActionId.CONTAINER_ADD_DOCUMENT, addDocumentData)); if(isOnline()) { jPopupMenu.addSeparator(); final Data publishData = new Data(1); publishData.set(Publish.DataKey.CONTAINER_ID, getId()); jPopupMenu.add(popupItemFactory.createPopupItem(ActionId.CONTAINER_PUBLISH, publishData)); final Data deleteDraftData = new Data(1); deleteData.set(DeleteDraft.DataKey.CONTAINER_ID, getId()); jPopupMenu.add(popupItemFactory.createPopupItem(ActionId.CONTAINER_DELETE_DRAFT, deleteDraftData)); } jPopupMenu.addSeparator(); jPopupMenu.add(popupItemFactory.createPopupItem(ActionId.CONTAINER_EXPORT, Data.emptyData())); final Data printData = new Data(1); printData.set(PrintDraft.DataKey.CONTAINER_ID, getId()); jPopupMenu.add(popupItemFactory.createPopupItem(ActionId.CONTAINER_PRINT_DRAFT, printData)); jPopupMenu.show(invoker, e.getX(), e.getY()); } |
jFileChooser.setFileSelectionMode(JFileChooser.FILES_ONLY); | private JFileChooser getJFileChooserForFileSelection() { if(null == jFileChooser) { jFileChooser = new JFileChooser(); jFileChooser.setMultiSelectionEnabled(Boolean.TRUE); jFileChooser.setFileSelectionMode(JFileChooser.FILES_ONLY); } jFileChooser.setCurrentDirectory(persistence.get( Keys.Persistence.JFILECHOOSER_CURRENT_DIRECTORY_FILE_SELECTION, (File) null)); return jFileChooser; } |
|
jFileChooser.setFileSelectionMode(JFileChooser.FILES_ONLY); | private JFileChooser getJFileChooserForFileSelection() { if(null == jFileChooser) { jFileChooser = new JFileChooser(); jFileChooser.setMultiSelectionEnabled(Boolean.TRUE); jFileChooser.setFileSelectionMode(JFileChooser.FILES_ONLY); } jFileChooser.setCurrentDirectory(persistence.get( Keys.Persistence.JFILECHOOSER_CURRENT_DIRECTORY_FILE_SELECTION, (File) null)); return jFileChooser; } |
|
jFileChooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY); | private JFileChooser getJFileChooserForFolderSelection() { if(null == jFileChooser) { jFileChooser = new JFileChooser(); jFileChooser.setMultiSelectionEnabled(Boolean.FALSE); jFileChooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY); } jFileChooser.setCurrentDirectory(persistence.get( Keys.Persistence.JFILECHOOSER_CURRENT_DIRECTORY_FOLDER_SELECTION, (File) null)); return jFileChooser; } |
|
jFileChooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY); | private JFileChooser getJFileChooserForFolderSelection() { if(null == jFileChooser) { jFileChooser = new JFileChooser(); jFileChooser.setMultiSelectionEnabled(Boolean.FALSE); jFileChooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY); } jFileChooser.setCurrentDirectory(persistence.get( Keys.Persistence.JFILECHOOSER_CURRENT_DIRECTORY_FOLDER_SELECTION, (File) null)); return jFileChooser; } |
|
public void mouseClicked(java.awt.event.MouseEvent evt) { | public void mouseClicked(final java.awt.event.MouseEvent evt) { | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane versionsContentJScrollPane; javax.swing.JScrollPane versionsJScrollPane; versionsJSplitPane = new javax.swing.JSplitPane(); leftJPanel = new javax.swing.JPanel(); versionsJScrollPane = new javax.swing.JScrollPane(); versionsJList = new javax.swing.JList(); rightJPanel = new javax.swing.JPanel(); versionsContentJScrollPane = new javax.swing.JScrollPane(); versionsContentJList = new javax.swing.JList(); setLayout(new java.awt.GridBagLayout()); setOpaque(false); versionsJSplitPane.setBorder(null); versionsJSplitPane.setDividerSize(0); versionsJSplitPane.setResizeWeight(0.5); versionsJSplitPane.setMinimumSize(new java.awt.Dimension(52, 75)); leftJPanel.setLayout(new java.awt.GridBagLayout()); leftJPanel.setBackground(new java.awt.Color(255, 255, 255)); leftJPanel.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { leftJPanelMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { leftJPanelMousePressed(evt); } }); versionsJScrollPane.setBorder(null); versionsJList.setModel(versionsModel); versionsJList.setCellRenderer(new VersionCellRenderer()); versionsJList.setVisibleRowCount(5); versionsJList.addListSelectionListener(new javax.swing.event.ListSelectionListener() { public void valueChanged(javax.swing.event.ListSelectionEvent evt) { versionsJListValueChanged(evt); } }); versionsJList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { versionsJListMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { versionsJListMousePressed(evt); } public void mouseReleased(java.awt.event.MouseEvent evt) { versionsJListMouseReleased(evt); } }); versionsJScrollPane.setViewportView(versionsJList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(3, 4, 4, 1); leftJPanel.add(versionsJScrollPane, gridBagConstraints); versionsJSplitPane.setLeftComponent(leftJPanel); rightJPanel.setLayout(new java.awt.GridBagLayout()); rightJPanel.setBackground(new java.awt.Color(255, 255, 255)); rightJPanel.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { rightJPanelMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { rightJPanelMousePressed(evt); } }); versionsContentJScrollPane.setBorder(null); versionsContentJList.setModel(versionsContentModel); versionsContentJList.setCellRenderer(new VersionContentCellRenderer()); versionsContentJList.setVisibleRowCount(5); versionsContentJList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { versionsContentJListMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { versionsContentJListMousePressed(evt); } public void mouseReleased(java.awt.event.MouseEvent evt) { versionsContentJListMouseReleased(evt); } }); versionsContentJScrollPane.setViewportView(versionsContentJList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(3, 1, 4, 4); rightJPanel.add(versionsContentJScrollPane, gridBagConstraints); versionsJSplitPane.setRightComponent(rightJPanel); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; add(versionsJSplitPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
public void mousePressed(java.awt.event.MouseEvent evt) { | public void mousePressed(final java.awt.event.MouseEvent evt) { | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane versionsContentJScrollPane; javax.swing.JScrollPane versionsJScrollPane; versionsJSplitPane = new javax.swing.JSplitPane(); leftJPanel = new javax.swing.JPanel(); versionsJScrollPane = new javax.swing.JScrollPane(); versionsJList = new javax.swing.JList(); rightJPanel = new javax.swing.JPanel(); versionsContentJScrollPane = new javax.swing.JScrollPane(); versionsContentJList = new javax.swing.JList(); setLayout(new java.awt.GridBagLayout()); setOpaque(false); versionsJSplitPane.setBorder(null); versionsJSplitPane.setDividerSize(0); versionsJSplitPane.setResizeWeight(0.5); versionsJSplitPane.setMinimumSize(new java.awt.Dimension(52, 75)); leftJPanel.setLayout(new java.awt.GridBagLayout()); leftJPanel.setBackground(new java.awt.Color(255, 255, 255)); leftJPanel.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { leftJPanelMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { leftJPanelMousePressed(evt); } }); versionsJScrollPane.setBorder(null); versionsJList.setModel(versionsModel); versionsJList.setCellRenderer(new VersionCellRenderer()); versionsJList.setVisibleRowCount(5); versionsJList.addListSelectionListener(new javax.swing.event.ListSelectionListener() { public void valueChanged(javax.swing.event.ListSelectionEvent evt) { versionsJListValueChanged(evt); } }); versionsJList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { versionsJListMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { versionsJListMousePressed(evt); } public void mouseReleased(java.awt.event.MouseEvent evt) { versionsJListMouseReleased(evt); } }); versionsJScrollPane.setViewportView(versionsJList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(3, 4, 4, 1); leftJPanel.add(versionsJScrollPane, gridBagConstraints); versionsJSplitPane.setLeftComponent(leftJPanel); rightJPanel.setLayout(new java.awt.GridBagLayout()); rightJPanel.setBackground(new java.awt.Color(255, 255, 255)); rightJPanel.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { rightJPanelMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { rightJPanelMousePressed(evt); } }); versionsContentJScrollPane.setBorder(null); versionsContentJList.setModel(versionsContentModel); versionsContentJList.setCellRenderer(new VersionContentCellRenderer()); versionsContentJList.setVisibleRowCount(5); versionsContentJList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { versionsContentJListMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { versionsContentJListMousePressed(evt); } public void mouseReleased(java.awt.event.MouseEvent evt) { versionsContentJListMouseReleased(evt); } }); versionsContentJScrollPane.setViewportView(versionsContentJList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(3, 1, 4, 4); rightJPanel.add(versionsContentJScrollPane, gridBagConstraints); versionsJSplitPane.setRightComponent(rightJPanel); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; add(versionsJSplitPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
public void mouseReleased(java.awt.event.MouseEvent evt) { | public void mouseReleased(final java.awt.event.MouseEvent evt) { | private void initComponents() { java.awt.GridBagConstraints gridBagConstraints; javax.swing.JScrollPane versionsContentJScrollPane; javax.swing.JScrollPane versionsJScrollPane; versionsJSplitPane = new javax.swing.JSplitPane(); leftJPanel = new javax.swing.JPanel(); versionsJScrollPane = new javax.swing.JScrollPane(); versionsJList = new javax.swing.JList(); rightJPanel = new javax.swing.JPanel(); versionsContentJScrollPane = new javax.swing.JScrollPane(); versionsContentJList = new javax.swing.JList(); setLayout(new java.awt.GridBagLayout()); setOpaque(false); versionsJSplitPane.setBorder(null); versionsJSplitPane.setDividerSize(0); versionsJSplitPane.setResizeWeight(0.5); versionsJSplitPane.setMinimumSize(new java.awt.Dimension(52, 75)); leftJPanel.setLayout(new java.awt.GridBagLayout()); leftJPanel.setBackground(new java.awt.Color(255, 255, 255)); leftJPanel.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { leftJPanelMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { leftJPanelMousePressed(evt); } }); versionsJScrollPane.setBorder(null); versionsJList.setModel(versionsModel); versionsJList.setCellRenderer(new VersionCellRenderer()); versionsJList.setVisibleRowCount(5); versionsJList.addListSelectionListener(new javax.swing.event.ListSelectionListener() { public void valueChanged(javax.swing.event.ListSelectionEvent evt) { versionsJListValueChanged(evt); } }); versionsJList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { versionsJListMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { versionsJListMousePressed(evt); } public void mouseReleased(java.awt.event.MouseEvent evt) { versionsJListMouseReleased(evt); } }); versionsJScrollPane.setViewportView(versionsJList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(3, 4, 4, 1); leftJPanel.add(versionsJScrollPane, gridBagConstraints); versionsJSplitPane.setLeftComponent(leftJPanel); rightJPanel.setLayout(new java.awt.GridBagLayout()); rightJPanel.setBackground(new java.awt.Color(255, 255, 255)); rightJPanel.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { rightJPanelMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { rightJPanelMousePressed(evt); } }); versionsContentJScrollPane.setBorder(null); versionsContentJList.setModel(versionsContentModel); versionsContentJList.setCellRenderer(new VersionContentCellRenderer()); versionsContentJList.setVisibleRowCount(5); versionsContentJList.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { versionsContentJListMouseClicked(evt); } public void mousePressed(java.awt.event.MouseEvent evt) { versionsContentJListMousePressed(evt); } public void mouseReleased(java.awt.event.MouseEvent evt) { versionsContentJListMouseReleased(evt); } }); versionsContentJScrollPane.setViewportView(versionsContentJList); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; gridBagConstraints.insets = new java.awt.Insets(3, 1, 4, 4); rightJPanel.add(versionsContentJScrollPane, gridBagConstraints); versionsJSplitPane.setRightComponent(rightJPanel); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; add(versionsJSplitPane, gridBagConstraints); }// </editor-fold>//GEN-END:initComponents |
public void mouseClicked(java.awt.event.MouseEvent evt) { | public void mouseClicked(final java.awt.event.MouseEvent evt) { | public void mouseClicked(java.awt.event.MouseEvent evt) { versionsJListMouseClicked(evt); } |
public void mousePressed(java.awt.event.MouseEvent evt) { | public void mousePressed(final java.awt.event.MouseEvent evt) { | public void mousePressed(java.awt.event.MouseEvent evt) { versionsJListMousePressed(evt); } |
public void mouseReleased(java.awt.event.MouseEvent evt) { | public void mouseReleased(final java.awt.event.MouseEvent evt) { | public void mouseReleased(java.awt.event.MouseEvent evt) { versionsJListMouseReleased(evt); } |
public void mouseClicked(java.awt.event.MouseEvent evt) { | public void mouseClicked(final java.awt.event.MouseEvent evt) { | public void mouseClicked(java.awt.event.MouseEvent evt) { versionsContentJListMouseClicked(evt); } |
public void mousePressed(java.awt.event.MouseEvent evt) { | public void mousePressed(final java.awt.event.MouseEvent evt) { | public void mousePressed(java.awt.event.MouseEvent evt) { versionsContentJListMousePressed(evt); } |
public void mouseReleased(java.awt.event.MouseEvent evt) { | public void mouseReleased(final java.awt.event.MouseEvent evt) { | public void mouseReleased(java.awt.event.MouseEvent evt) { versionsContentJListMouseReleased(evt); } |
this.logger = LoggerFactory.getLogger(getClass()); | public Tray(final SystemApplication systemApplication) { super(); this.menuBuilder = new TrayMenuBuilder(systemApplication); this.isInstalled = Boolean.FALSE; this.systemApplication = systemApplication; } |
|
updateMenu(); | reloadConnectionStatus(systemApplication.getConnectionStatus()); | public void install() { systemTrayIcon = new TrayIcon(readTrayIcon()); systemTrayIcon.addActionListener(new ActionListener() { public void actionPerformed(final ActionEvent e) { if(systemApplication.isBrowserRunning()) systemApplication.runMoveBrowserToFront(); else systemApplication.runRestoreBrowser(); } }); systemTrayIcon.setPopupMenu(menuBuilder.createPopup()); systemTrayIcon.setIconAutoSize(true); systemTray = SystemTray.getDefaultSystemTray(); systemTray.addTrayIcon(systemTrayIcon); isInstalled = Boolean.TRUE; updateMenu(); } |
jPopupMenu.add(createMenuItem( "Menu.Browser", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }})); | jPopupMenu.add(browser); jPopupMenu.add(editProfile); | JPopupMenu createPopup() { final JPopupMenu jPopupMenu = MenuFactory.createPopup(); jPopupMenu.add(createMenuItem( "Menu.Browser", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }})); jPopupMenu.addSeparator(); jPopupMenu.add(login); jPopupMenu.add(logout); jPopupMenu.add(createMenuItem( "Menu.About", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.displayAbout(); } })); jPopupMenu.addSeparator(); jPopupMenu.add(createMenuItem( "Menu.Exit", new ActionListener() { public void actionPerformed(ActionEvent e) { application.runExitPlatform(); } })); return jPopupMenu; } |
jPopupMenu.add(createMenuItem( "Menu.About", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.displayAbout(); } })); | jPopupMenu.add(about); | JPopupMenu createPopup() { final JPopupMenu jPopupMenu = MenuFactory.createPopup(); jPopupMenu.add(createMenuItem( "Menu.Browser", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }})); jPopupMenu.addSeparator(); jPopupMenu.add(login); jPopupMenu.add(logout); jPopupMenu.add(createMenuItem( "Menu.About", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.displayAbout(); } })); jPopupMenu.addSeparator(); jPopupMenu.add(createMenuItem( "Menu.Exit", new ActionListener() { public void actionPerformed(ActionEvent e) { application.runExitPlatform(); } })); return jPopupMenu; } |
jPopupMenu.add(createMenuItem( "Menu.Exit", new ActionListener() { public void actionPerformed(ActionEvent e) { application.runExitPlatform(); } })); | jPopupMenu.add(exit); | JPopupMenu createPopup() { final JPopupMenu jPopupMenu = MenuFactory.createPopup(); jPopupMenu.add(createMenuItem( "Menu.Browser", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }})); jPopupMenu.addSeparator(); jPopupMenu.add(login); jPopupMenu.add(logout); jPopupMenu.add(createMenuItem( "Menu.About", new ActionListener() { public void actionPerformed(final ActionEvent e) { application.displayAbout(); } })); jPopupMenu.addSeparator(); jPopupMenu.add(createMenuItem( "Menu.Exit", new ActionListener() { public void actionPerformed(ActionEvent e) { application.runExitPlatform(); } })); return jPopupMenu; } |
removeAll(); | jListModel.clear(); | public void reload() { removeAll(); if(null != input && 2 == ((Object[]) input).length) { reloadSystemMessages(); reloadDocuments(); } final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.BOTH; c.gridx = 0; c.weightx = 1.0; c.weighty = 1.0; add(LabelFactory.create(), c.clone()); revalidate(); repaint(); } |
final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.BOTH; c.gridx = 0; c.weightx = 1.0; c.weighty = 1.0; add(LabelFactory.create(), c.clone()); revalidate(); repaint(); | public void reload() { removeAll(); if(null != input && 2 == ((Object[]) input).length) { reloadSystemMessages(); reloadDocuments(); } final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.BOTH; c.gridx = 0; c.weightx = 1.0; c.weighty = 1.0; add(LabelFactory.create(), c.clone()); revalidate(); repaint(); } |
|
final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); | private void reloadDocuments() { final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); final Object[] elements = ((CompositeFlatContentProvider) contentProvider).getElements(1, ((Object[]) input)[1]); BrowserMainListItem mainListItem; for(final Object element : elements) { mainListItem = new BrowserMainListItemDocument(this, (Document) element); add(mainListItem, c.clone()); } } |
|
BrowserMainListItem mainListItem; | private void reloadDocuments() { final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); final Object[] elements = ((CompositeFlatContentProvider) contentProvider).getElements(1, ((Object[]) input)[1]); BrowserMainListItem mainListItem; for(final Object element : elements) { mainListItem = new BrowserMainListItemDocument(this, (Document) element); add(mainListItem, c.clone()); } } |
|
mainListItem = new BrowserMainListItemDocument(this, (Document) element); add(mainListItem, c.clone()); | jListModel.addElement(new DocumentListItem((Document) element)); | private void reloadDocuments() { final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); final Object[] elements = ((CompositeFlatContentProvider) contentProvider).getElements(1, ((Object[]) input)[1]); BrowserMainListItem mainListItem; for(final Object element : elements) { mainListItem = new BrowserMainListItemDocument(this, (Document) element); add(mainListItem, c.clone()); } } |
final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); | private void reloadSystemMessages() { final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); final Object[] elements = ((CompositeFlatContentProvider) contentProvider).getElements(0, ((Object[]) input)[0]); BrowserMainListItem mainListItem; for(Object element : elements) { mainListItem = new BrowserMainListItemSystemMessage(this, (Message) element); add(mainListItem, c.clone()); } } |
|
BrowserMainListItem mainListItem; | private void reloadSystemMessages() { final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); final Object[] elements = ((CompositeFlatContentProvider) contentProvider).getElements(0, ((Object[]) input)[0]); BrowserMainListItem mainListItem; for(Object element : elements) { mainListItem = new BrowserMainListItemSystemMessage(this, (Message) element); add(mainListItem, c.clone()); } } |
|
mainListItem = new BrowserMainListItemSystemMessage(this, (Message) element); add(mainListItem, c.clone()); | jListModel.addElement(BrowserMainListItem.create((Message) element)); | private void reloadSystemMessages() { final GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.HORIZONTAL; c.gridx = 0; c.weightx = 1.0; c.insets = new Insets(0, 0, 1, 0); final Object[] elements = ((CompositeFlatContentProvider) contentProvider).getElements(0, ((Object[]) input)[0]); BrowserMainListItem mainListItem; for(Object element : elements) { mainListItem = new BrowserMainListItemSystemMessage(this, (Message) element); add(mainListItem, c.clone()); } } |
public void setState(State state) {} | public void setState(final State state) {} | public void setState(State state) {} |
catch(final Throwable t) { logger.fatal("[RMODEL] [PLUGIN] [INIT CONTROLLER]", t); } | private void initializeController(final String controllerName) { try { controllers.add((IQHandler) Class.forName(controllerName).newInstance()); } catch(final ClassNotFoundException cnfx) { logger.fatal("[RMODEL] [PLUGIN] [INIT CONTROLLER]", cnfx); } catch(final IllegalAccessException iax) { logger.fatal("[RMODEL] [PLUGIN] [INIT CONTROLLER]", iax); } catch(final InstantiationException ix) { logger.fatal("[RMODEL] [PLUGIN] [INIT CONTROLLER]", ix); } final IQHandler controller = controllers.get(controllers.size() - 1); iqRouter.addHandler(controller); final String info = MessageFormat.format( "[RMODEL] [PLUGIN] [INIT CONTROLLER] [{0} REGISTERED]", new Object[] {controller.getInfo().getNamespace()}); logger.info(info); } |
|
initializeController("com.thinkparity.server.handler.document.Reactivate"); | private void initializeControllers() { synchronized(controllers) { initializeController("com.thinkparity.server.handler.artifact.AcceptKeyRequest"); initializeController("com.thinkparity.server.handler.artifact.CloseArtifact"); initializeController("com.thinkparity.server.handler.artifact.ConfirmReceipt"); initializeController("com.thinkparity.server.handler.artifact.CreateArtifact"); initializeController("com.thinkparity.server.handler.artifact.DeleteArtifact"); initializeController("com.thinkparity.server.handler.artifact.DenyKeyRequest"); initializeController("com.thinkparity.server.handler.artifact.FlagArtifact"); initializeController("com.thinkparity.server.handler.artifact.GetArtifactKeys"); initializeController("com.thinkparity.server.handler.artifact.GetKeyHolder"); initializeController("com.thinkparity.server.handler.artifact.GetSubscription"); initializeController("com.thinkparity.server.handler.artifact.ReadContacts"); initializeController("com.thinkparity.server.handler.artifact.RequestArtifactKey"); initializeController("com.thinkparity.server.handler.contact.AcceptInvitation"); initializeController("com.thinkparity.server.handler.contact.DeclineInvitation"); initializeController("com.thinkparity.server.handler.contact.InviteContact"); initializeController("com.thinkparity.server.handler.contact.ReadContacts"); initializeController("com.thinkparity.server.handler.document.SendDocument"); initializeController("com.thinkparity.server.handler.queue.ProcessOfflineQueue"); initializeController("com.thinkparity.server.handler.user.ReadUsers"); initializeController("com.thinkparity.server.handler.user.SubscribeUser"); initializeController("com.thinkparity.server.handler.user.UnsubscribeUser"); } } |
|
public AirBrush(String plugname, String hostname, Integer port) { connect(plugname, hostname, port); | public AirBrush(String moduleName, String hostname, Integer port) { connect(moduleName, hostname, port); this.moduleName = moduleName; | public AirBrush(String plugname, String hostname, Integer port) { connect(plugname, hostname, port); } |
return plug.getParameterString(key); | System.err.println("Getting parameter " + moduleName + ":" + key); return plug.getParameterString(moduleName, key); | public String getParameterString(String key) { return plug.getParameterString(key); } |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.