Search in sources :

Example 36 with DataTablePopupMenu

use of com.att.aro.ui.model.DataTablePopupMenu in project VideoOptimzer by attdevsupport.

the class BpConnectionsHttp4xx5xxTablePanel method getContentTable.

/**
 * Initializes and returns the RequestResponseTable.
 */
@SuppressWarnings("unchecked")
public DataTable<Http4xx5xxStatusResponseCodesEntry> getContentTable() {
    if (contentTable == null) {
        contentTable = new DataTable<Http4xx5xxStatusResponseCodesEntry>(tableModel);
        contentTable.setName(ResourceBundleHelper.getMessageString("connections.400.500.response.tableName"));
        contentTable.setAutoCreateRowSorter(true);
        contentTable.setGridColor(Color.LIGHT_GRAY);
        contentTable.setRowHeight(ROW_HEIGHT);
        contentTable.setAutoResizeMode(JTable.AUTO_RESIZE_SUBSEQUENT_COLUMNS);
        DataTablePopupMenu popupMenu = (DataTablePopupMenu) contentTable.getPopup();
        popupMenu.initialize();
    }
    return contentTable;
}
Also used : Http4xx5xxStatusResponseCodesEntry(com.att.aro.core.bestpractice.pojo.Http4xx5xxStatusResponseCodesEntry) DataTablePopupMenu(com.att.aro.ui.model.DataTablePopupMenu)

Example 37 with DataTablePopupMenu

use of com.att.aro.ui.model.DataTablePopupMenu in project VideoOptimzer by attdevsupport.

the class SelectProfileDialog method getProfilesTable.

/**
 * Initializes and returns the JTable that displays the the list of
 * predefined profiles with their types on the SElect Profile dialog.
 */
private DataTable<Profile> getProfilesTable() {
    if (jProfilesTable == null) {
        MessageDialogFactory dialog = new MessageDialogFactory();
        try {
            jProfilesTable = new DataTable<Profile>(new ProfileListTableModel(ProfileManager.getInstance().getPredefinedProfilesList()));
            jProfilesTable.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
            jProfilesTable.getSelectionModel().addListSelectionListener(new ListSelectionListener() {

                @Override
                public void valueChanged(ListSelectionEvent e) {
                    if (jProfilesTable.getSelectedRowCount() != -1) {
                        getOpenButton().setEnabled(true);
                    }
                    getFilenameTextField().setText(null);
                }
            });
            DataTablePopupMenu popupMenu = (DataTablePopupMenu) jProfilesTable.getPopup();
            popupMenu.initialize();
        } catch (IOException e) {
            dialog.showErrorDialog(SelectProfileDialog.this, MessageFormat.format(ResourceBundleHelper.getMessageString("profile.profileListError"), e.getMessage()));
        } catch (ProfileException e) {
            dialog.showErrorDialog(SelectProfileDialog.this, MessageFormat.format(ResourceBundleHelper.getMessageString("profile.profileListError"), e.getMessage()));
        }
    }
    return jProfilesTable;
}
Also used : ListSelectionEvent(javax.swing.event.ListSelectionEvent) DataTablePopupMenu(com.att.aro.ui.model.DataTablePopupMenu) MessageDialogFactory(com.att.aro.ui.commonui.MessageDialogFactory) IOException(java.io.IOException) Profile(com.att.aro.core.configuration.pojo.Profile) ListSelectionListener(javax.swing.event.ListSelectionListener)

Aggregations

DataTablePopupMenu (com.att.aro.ui.model.DataTablePopupMenu)37 TableModel (javax.swing.table.TableModel)12 TableRowSorter (javax.swing.table.TableRowSorter)12 ListSelectionEvent (javax.swing.event.ListSelectionEvent)5 ListSelectionListener (javax.swing.event.ListSelectionListener)5 HttpRequestResponseInfo (com.att.aro.core.packetanalysis.pojo.HttpRequestResponseInfo)4 MinificationEntry (com.att.aro.core.bestpractice.pojo.MinificationEntry)2 CacheEntry (com.att.aro.core.packetanalysis.pojo.CacheEntry)2 Session (com.att.aro.core.packetanalysis.pojo.Session)2 MessageDialogFactory (com.att.aro.ui.commonui.MessageDialogFactory)2 SimultnsConnTableModel (com.att.aro.ui.model.bestpractice.SimultnsConnTableModel)2 AccessedDomainsTableModel (com.att.aro.ui.model.overview.AccessedDomainsTableModel)2 ExpandedDomainTableModel (com.att.aro.ui.model.overview.ExpandedDomainTableModel)2 MouseAdapter (java.awt.event.MouseAdapter)2 MouseEvent (java.awt.event.MouseEvent)2 IOException (java.io.IOException)2 AsyncCheckEntry (com.att.aro.core.bestpractice.pojo.AsyncCheckEntry)1 DisplayNoneInCSSEntry (com.att.aro.core.bestpractice.pojo.DisplayNoneInCSSEntry)1 FileOrderEntry (com.att.aro.core.bestpractice.pojo.FileOrderEntry)1 ForwardSecrecyEntry (com.att.aro.core.bestpractice.pojo.ForwardSecrecyEntry)1