Package com.onpositive.commons.ui.dialogs

Examples of com.onpositive.commons.ui.dialogs.TitledDialog


            .setName("Remember password(Could trigger secure storage login)");
        ButtonSelector sl = new ButtonSelector(binding2);
        compositeEditor.add(element);
        compositeEditor.add(sl);

        TitledDialog t = new TitledDialog(compositeEditor);
        DisposeBindingListener.linkBindingLifeCycle(binding,
            compositeEditor);
        int open = t.open();
        options.ok = open == Dialog.OK;
      }
    });
    if (options.ok) {
      ConnectOptions cm = new ConnectOptions();
View Full Code Here


    bnd.setAutoCommit(true);
    bnd.setName(e.getKey().toString());
    editor.setBinding(bnd);

    final TitledDialog dlg = new EditDialog(editor, true);
    dlg.setResizable(true);
    ArrayList<Entity> al = new ArrayList();
    al.add((Entity) selection);
    Field[] fields = facade.determineFields(al);

    bnd.switchParsingMode(true);
    EditorUtility.createBindingsWithButton(e, editor, bnd, fields, facade,
        true);
    DisposeBindingListener.linkBindingLifeCycle(bnd, editor);
    dlg.open();
  }
View Full Code Here

    bnd.setAutoCommit(true);
    bnd.setName(e.getKey().toString());
    editor.setBinding(bnd);

    final TitledDialog dlg = new EditDialog(editor, drawParentLink);//
    dlg.setResizable(true);

    // Field[] p = facade.getpFields();
    Field[] full = getAllFields();
    bnd.switchParsingMode(true);
    EditorUtility.createBindingsWithButton(e, editor, bnd, full, facade,
        true);
    DisposeBindingListener.linkBindingLifeCycle(bnd, editor);
    dlg.create();
    int ch = dlg.open();

    if (ch == Window.OK) {
      return true;
    }
View Full Code Here

    bnd.setAutoCommit(true);
    bnd.setName(e.getKey().toString());
    editor.setBinding(bnd);

    final TitledDialog dlg = new EditDialog(editor, drawParentLink);//
    if (callBList != null)
      ;
    ((EditDialog) dlg).setUpdatingCallback(callBList);
    dlg.setResizable(true);

    Field[] full = getAllFields();
    EditorUtility.createBindingsWithButton(e, editor, bnd, full, facade,
        true);
    DisposeBindingListener.linkBindingLifeCycle(bnd, editor);

    dlg.open();
  }
View Full Code Here

    bnd.setAutoCommit(true);
    bnd.setName(e.getKey().toString());
    editor.setBinding(bnd);

    final TitledDialog dlg = new EditDialog(editor, drawParentLink);//
    if (callBList != null)
      ;
    ((EditDialog) dlg).setUpdatingCallback(callBList);
    dlg.setResizable(true);

    Field[] full = getAllFields();
    EditorUtility.createBindingsWithButton(e, editor, bnd, full, facade,
        true);
    DisposeBindingListener.linkBindingLifeCycle(bnd, editor);
    dlg.open();
  }
View Full Code Here

        OneLineTextElement<String> f = new OneLineTextElement(
            currNSBinding);
        ce.setLayout(new FillLayout());
        ce.add(f);

        TitledDialog td = new TitledDialog(ce) {

          protected void okPressed() {
            currNSBinding.commit();
            super.okPressed();
          }

          public int open() {
            int ch = super.open();
            return ch;
          }
        };
        td.create();
        td.getShell().setSize(300, 190);
        td.open();

        String curr = (String) currNSBinding.getValue();

        if (!l.getRealm().contains(curr)) {// curr.length() != 0) {
          l.addValue(curr);
View Full Code Here

       * OneLineTextElement<String>(); t.setBinding(binding);
       * editor.add(t); }
       */
    }

    final TitledDialog dlg = new EditDialog(editor);
    dlg.setResizable(false);
    DisposeBindingListener.linkBindingLifeCycle(bnd, editor);
    int code = dlg.open();
    if (code == Window.OK) {
      return true;
    } else {
      return false;
    }
View Full Code Here

          final Class clz = serialized.getClass();
          parentBnd.setName(clz.getCanonicalName());
          CompositeEditor editor = new CompositeEditor(parentBnd);
          EditorUtility.createBindingsForType(clz, parentBnd, editor,
              project);
          TitledDialog td = new TitledDialog(parentBnd, editor) {
            protected void okPressed() {
              parentBnd.commit();
              if (updater != null) {
                Object value = parentBnd.getValue();
                ByteArrayOutputStream bos = new ByteArrayOutputStream();
                try {
                  ObjectOutputStream oos = new ObjectOutputStream(
                      bos);
                  oos.writeObject(value);
                  byte[] array = bos.toByteArray();
                  updater.updateBlob(array);
                } catch (IOException e) {
                  Activator.log(e);
                }
              }
              super.okPressed();
            };
          };
          td.open();
        }
      }
    });

  }
View Full Code Here

      if (rStr.size() != 0) {
        combo.setValue(rStr.toArray()[0], null);
      }

      TitledDialog tid = new TitledDialog(editor) {

        protected void okPressed() {
          ((Binding) value).commit();
          Map<String, Object> map = res.getProperties();
          for (String s : map.keySet()) {
            if (fillDefault) {
              facade.setPropertyValue(s, res, true, callback);
            } else {
              facade.setPropertyValue(s, res, false, callback);
            }
            break;

          }
          super.okPressed();
        }
      };
      // tid.getShell().pack(true);
      tid.open();
    }
View Full Code Here

      editor.setBinding(bnd);
      // Field[] full = getAllFields();
      EditorUtility.createBindingsWithButton(entity, editor, bnd,
          facade.getFields(), facade, true);

      final TitledDialog dlg = new EditDialog(editor, true);
      dlg.setResizable(true);
      DisposeBindingListener.linkBindingLifeCycle(bnd, editor);
      dlg.open();
    }
View Full Code Here

TOP

Related Classes of com.onpositive.commons.ui.dialogs.TitledDialog

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.