Package org.jnode.apps.jpartition.model

Examples of org.jnode.apps.jpartition.model.Device


                                "Format selection", JOptionPane.PLAIN_MESSAGE, null, options,
                                options[0]);

                if ((option != null) && (option.length() > 0)) {
                    UserFacade.getInstance().selectFormatter(option);
                    Device dev = UserFacade.getInstance().getSelectedDevice();
                    try {
                        UserFacade.getInstance().formatPartition(dev.getStart());
                    } catch (Exception e1) {
                        errorReporter.reportError(log, FormatPartitionAction.this, e1);
                    }
                    view.update();
                }
View Full Code Here


    }

    public void actionPerformed(ActionEvent e) {
        SwingUtilities.invokeLater(new Runnable() {
            public void run() {
                final Device dev = UserFacade.getInstance().getSelectedDevice();

                final JDialog dlg = new JDialog((Dialog) null, "create new partition", true);
                final SpinnerNumberModel spn = new SpinnerNumberModel(10, 1, dev.getSize(), 10);
                dlg.getContentPane().setLayout(new FlowLayout());
                dlg.getContentPane().add(new JLabel("size : "));
                dlg.getContentPane().add(new JSpinner(spn));
                JButton btn = new JButton("Add partition");
                btn.addActionListener(new ActionListener() {
View Full Code Here

        boolean deviceSelected = false;

        List<Device> devices = UserFacade.getInstance().getDevices();
        if ((devices != null) && !devices.isEmpty()) {
            Options devicesOpt = new Options(context);
            Device choice =
                    devicesOpt.show("Select a device", devices, DeviceLabelizer.INSTANCE);

            String device = choice.getName();
            UserFacade.getInstance().selectDevice(device);
            println("device=" + device);
            deviceSelected = true;
        }
View Full Code Here

TOP

Related Classes of org.jnode.apps.jpartition.model.Device

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.