예제 #1
0
 public int showDialog(Component parent) {
   parentDialog = new JXDialog(this);
   parentDialog.setTitle("New media (" + categories + ")");
   parentDialog.setContentPane(this);
   parentDialog.setModal(true);
   parentDialog.setMinimumSize(new Dimension(300, 300));
   // dialog.setPreferredSize(new Dimension(500,400));
   parentDialog.setDefaultCloseOperation(JXDialog.DISPOSE_ON_CLOSE);
   GKit.popup(parent, parentDialog);
   return selectedOption;
 }
예제 #2
0
 public static int showCreateDialog(
     Component parent, List<ICategory> category, String initialName, String format) {
   MediaCreator mcd = new MediaCreator(category, initialName, format);
   JXDialog dialog = new JXDialog(mcd);
   mcd.parentDialog = dialog;
   // ============== le dialog
   dialog.setTitle("New media (" + category + ")");
   dialog.setContentPane(mcd);
   dialog.setModal(true);
   dialog.setMinimumSize(new Dimension(300, 300));
   // dialog.setPreferredSize(new Dimension(500,400));
   dialog.setDefaultCloseOperation(JXDialog.DISPOSE_ON_CLOSE);
   GKit.popup(dialog);
   return mcd.selectedOption;
 }