Initialize the size, columns, and listener.  Size should be a pre-defined size (SIZE_LARGE
or SIZE_SMALL) from ColorPickerDialogFragment.
188998
public void init(int size, int columns, ColorPickerSwatch.OnColorSelectedListener listener) {
        mNumColumns = columns;
        Resources res = getResources();
        if (size == ColorPickerDialog.SIZE_LARGE) {
            mSwatchLength = res.getDimensionPixelSize(R.dimen.color_swatch_large);
            mMarginSize = res.getDimensionPixelSize(R.dimen.color_swatch_margins_large);
        } else {
            mSwatchLength = res.getDimensionPixelSize(R.dimen.color_swatch_small);
            mMarginSize = res.getDimensionPixelSize(R.dimen.color_swatch_margins_small);
        }
        mOnColorSelectedListener = listener;

        mDescription = res.getString(R.string.color_swatch_description);
        mDescriptionSelected = res.getString(R.string.color_swatch_description_selected);
    }
611585
private void initialize()
	{
		Log.addLogListener(new LogMessageCallBack()
		{
			@Override
			public void debug(String message)
			{
				showMessage(message);
			}
			@Override
			public void info(String message)
			{
				showMessage(message);
			}
			@Override
			public void error(String message, Throwable ex)
			{
				if (ex!=null)
					showMessage(message+'|'+ex.toString());
				else
					showMessage(message);
			}
		});
		
		readPropertyFile();
		
		setSystemTray();

		setName(WINDOW_NAME);
		setTitle(WINDOW_TITLE);
		getTrayIcon().setToolTip(WINDOW_TITLE);

		java.net.URL iconURL = MainForm.class.getResource(DEFAULTICONPATH);
	    if (iconURL!=null) 
	    	setIconImage(java.awt.Toolkit.getDefaultToolkit().getImage(iconURL));
		
	    setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
	    addWindowListener(new java.awt.event.WindowAdapter()
		{
			@Override
			public void windowClosing(java.awt.event.WindowEvent e)
			{
				doClose();
			}
			/**
			 * @param e
			 * @see java.awt.event.WindowAdapter#windowIconified(java.awt.event.WindowEvent)
			 * @since 07.02.2012
			 */
			@Override
			public void windowIconified(WindowEvent e)
			{
				if (useSystemTray) setVisible(false);
			}
			/**
			 * @param e
			 * @see java.awt.event.WindowAdapter#windowDeiconified(java.awt.event.WindowEvent)
			 * @since 07.02.2012
			 */
			@Override
			public void windowDeiconified(WindowEvent e)
			{
				if (useSystemTray) setVisible(true);
			}
		});
	    setSize(mainDialogSize);
		setPreferredSize(mainDialogSize);
		
		setJMenuBar(getBaseMenuBar());
		setContentPane(getBaseContentPane());
	    setPlayListIcons();
		// Volumecontrol by mousewheel:
	    addMouseWheelListener(new MouseWheelVolumeControl());
	    pack();

		createAllWindows();
		
		updateLookAndFeel(uiClassName);

		if (mainDialogLocation == null || (mainDialogLocation.getX()==-1 || mainDialogLocation.getY()==-1))
			mainDialogLocation = Helpers.getFrameCenteredLocation(this, null); 
	    setLocation(mainDialogLocation);
	    getModInfoDialog().setVisible(modInfoDialogVisable);
		getPlaylistDialog().setVisible(playlistDialogVisable);
		getEffectDialog().setVisible(effectDialogVisable);
		getPlayerSetUpDialog().setVisible(playerSetUpDialogVisable);

		dropTargetList = new ArrayList<DropTarget>();
	    PlaylistDropListener myListener = new PlaylistDropListener(this);
	    Helpers.registerDropListener(dropTargetList, this, myListener);
	    
		MultimediaContainerManager.addMultimediaContainerEventListener(this);
		
		createFileFilter();

	    currentContainer = null; //set Back to null!
	    showMessage("Ready...");
	}
341063
@Override
    public void initialize() throws InitializationException
    {
        ListenerChain chain = new ListenerChain();
        setListenerChain(chain);

        // Construct the listener chain in the right order. Listeners early in the chain are called before listeners
        // placed later in the chain.
        chain.addListener(this);
        chain.addListener(new HTMLMacroBlockStateChainingListener(chain));
        chain.addListener(new EmptyBlockChainingListener(chain));
        chain.addListener(new MetaDataStateChainingListener(chain));
        chain.addListener(new HTMLMacroXHTMLChainingRenderer(this.linkRenderer, this.imageRenderer, chain));
    }
138322
def _init(self):
        
        self.col_count = len(self.col_list)
        # list of lengths of longest entries in columns
        self.col_longest = self.get_all_longest_col_lengths()
        self.data_length = sum(self.col_longest.values())

        if self.terminal_width > 0:
            # free space is space which should be equeally distributed for all columns
            # self.terminal_width -- terminal is our canvas
            #  - self.data_length -- substract length of content (the actual data)
            #  - self.col_count + 1 -- table lines are not part of free space, their width is
            #                          (number of columns - 1)
            self.total_free_space = (self.terminal_width - self.data_length) - self.col_count + 1
            if self.total_free_space <= 0:
                self.total_free_space = None
            else:
                self.default_column_space = self.total_free_space // self.col_count
                self.default_column_space_remainder = self.total_free_space % self.col_count
                logger.debug("total free space: %d, column space: %d, remainder: %d, columns: %d",
                             self.total_free_space, self.default_column_space,
                             self.default_column_space_remainder, self.col_count)
        else:
            self.total_free_space = None
217194
private void initialize() {
		cardLayout = new CardLayout();
        this.setLayout(cardLayout);
        this.setName("AlertView");

        if (! editable) {
        	this.add(getDefaultPane(), getDefaultPane().getName());
        }
        this.add(getAlertPane(), getAlertPane().getName());
			
	}
994630
private static void grow(int size) throws IOException {
    for (int i = 0; i < size - maxSelectors; i++) {
      selectors.add(Selector.open());
    }
  }
597929
private void initialize() {
		this.setLayout(new CardLayout());
		this.setName(buildName(getContextIndex()));
		this.setLayout(new GridBagLayout());
		this.setBorder(new EmptyBorder(2, 2, 2, 2));

		this.add(new JLabel(LABEL_DESCRIPTION), LayoutHelper.getGBC(0, 0, 1, 1.0D));

		// Method type combo box
		this.add(new JLabel(FIELD_LABEL_TYPE_SELECT),
				LayoutHelper.getGBC(0, 1, 1, 1.0D, new Insets(20, 0, 5, 5)));
		this.add(getAuthenticationMethodsComboBox(), LayoutHelper.getGBC(0, 2, 1, 1.0D));

		// Method config panel container
		this.add(getConfigContainerPanel(), LayoutHelper.getGBC(0, 3, 1, 1.0d, new Insets(10, 0, 10, 0)));

		// Logged In/Out indicators
		this.add(new JLabel(FIELD_LABEL_LOGGED_IN_INDICATOR), LayoutHelper.getGBC(0, 4, 1, 1.0D));
		this.add(getLoggedInIndicaterRegexField(), LayoutHelper.getGBC(0, 5, 1, 1.0D));
		this.add(new JLabel(FIELD_LABEL_LOGGED_OUT_INDICATOR), LayoutHelper.getGBC(0, 6, 1, 1.0D));
		this.add(getLoggedOutIndicaterRegexField(), LayoutHelper.getGBC(0, 7, 1, 1.0D));

		// Padding
		this.add(new JLabel(), LayoutHelper.getGBC(0, 99, 1, 1.0D, 1.0D));
	}
1363618
private void init() {
        setTitle("Validation Framework Test");
        setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);

        // Add contents
        JPanel contentPane = new JPanel(new MigLayout("fill, wrap 1", "[]", "[grow]unrelated[]"));
        setContentPane(contentPane);

        contentPane.add(new JScrollPane(table), "grow");
        installValidators(table);
        contentPane.add(changeButton, "align right");

        // Set size
        pack();
        Dimension size = getSize();
        size.width += 100;
        setMinimumSize(size);

        // Set location
        Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
        setLocation((screenSize.width - size.width) / 2, (screenSize.height - size.height) / 3);
    }
1339530
private void initialize() {
    this.setSize(300, 200);
    this.setTitle("Connect");
    this.setContentPane(getJContentPane());
    this.setDefaultCloseOperation(DO_NOTHING_ON_CLOSE);
    this.addWindowListener(new WindowAdapter() {
      public void windowClosed(WindowEvent e) {
        cancelTimeout();
      }
    });

    Toolkit.getDefaultToolkit().addAWTEventListener(new AWTEventListener() {
      public void eventDispatched(AWTEvent e) {
        if ((e instanceof KeyEvent && ((KeyEvent) e).getID() == KeyEvent.KEY_PRESSED)
            || (e instanceof MouseEvent && ((MouseEvent) e).getID() == MouseEvent.MOUSE_PRESSED)) {
          if (ConnectionDialog.this.isAncestorOf(((ComponentEvent) e).getComponent())) {
            cancelTimeout();
          }
        }
      }
    }, AWTEvent.KEY_EVENT_MASK | AWTEvent.MOUSE_EVENT_MASK);
    restore();
  }
104170
private void init(final String title, final int initialWidth, final int initialHeight,
		final Component component)
	{
		if (title != null)
		{
			setTitle(title);
		}
		setInitialWidth(initialWidth);
		setInitialHeight(initialHeight);
		setContent(component);
	}
260950
private void initDialogObject() {

        Object o = getDialogObject();
        if (o != null) {
            m_settings = (CmsPropertyviewDialogSettings)o;
        } else {
            m_settings = new CmsPropertyviewDialogSettings();
            setDialogObject(m_settings);
        }
    }
997324
private void init(final int WIDTH, final int HEIGHT) {
        if (WIDTH <= 1 || HEIGHT <= 1) {
            return;
        }

        final double CORNER_RADIUS = WIDTH > HEIGHT ? (HEIGHT * 0.095) : (WIDTH * 0.095);
        if (recreateImages) {
            if (sparkLineBackgroundImage != null) {
                sparkLineBackgroundImage.flush();
            }
            sparkLineBackgroundImage = create_SPARK_LINE_BACKGROUND_Image(WIDTH, HEIGHT);

            // set the clip shape
            CLIP_SHAPE.setRoundRect(1, 1, WIDTH - 2, HEIGHT - 2, CORNER_RADIUS - 1, CORNER_RADIUS - 1);

            if (startIndicatorImage != null) {
                startIndicatorImage.flush();
            }
            //startIndicatorImage = createIndicatorImage(WIDTH, HEIGHT, ColorDef.GRAY);
            startIndicatorImage = create_START_STOP_INDICATOR_Image(WIDTH);

            if (stopIndicatorImage != null) {
                stopIndicatorImage.flush();
            }
            //stopIndicatorImage = createIndicatorImage(WIDTH, HEIGHT, ColorDef.GRAY);
            stopIndicatorImage = create_START_STOP_INDICATOR_Image(WIDTH);

            if (loIndicatorImage != null) {
                loIndicatorImage.flush();
            }
            //loIndicatorImage = createIndicatorImage(WIDTH, HEIGHT, ColorDef.BLUE);
            loIndicatorImage = create_LO_INDICATOR_Image(WIDTH);

            if (hiIndicatorImage != null) {
                hiIndicatorImage.flush();
            }
            //hiIndicatorImage = createIndicatorImage(WIDTH, HEIGHT, ColorDef.RED);
            hiIndicatorImage = create_HI_INDICATOR_Image(WIDTH);
        }
        recreateImages = false;

        disabledShape = new java.awt.geom.RoundRectangle2D.Double(0, 0, WIDTH, HEIGHT, CORNER_RADIUS, CORNER_RADIUS);

        // Calculation and creation of sparkline itself
        pixelResolution = INNER_BOUNDS.getWidth() / (double) timeFrame;
        //offset = (int)(0.015 * WIDTH) < 4 ? 4 : (int)(0.015 * WIDTH);
        offset = (int) (0.06 * WIDTH) < 8 ? 8 : (int) (0.06 * WIDTH);

        baseLineY = INNER_BOUNDS.y + INNER_BOUNDS.height - ((0 - lo) * (1 / scaleY) + offset);

        if (!DATA_LIST.isEmpty()) {
            calculate(WIDTH, HEIGHT);
        }

        if (sparkLineImage != null) {
            sparkLineImage.flush();
        }
        sparkLineImage = createSparkLineImage(WIDTH, HEIGHT);
    }
402151
private void initialize() {
        this.setContinuousLayout(true);
        this.setRightComponent(getJPanel1());
        // ZAP: added more space for readability (was 175)
        this.setDividerLocation(200);
        this.setDividerSize(3);
        this.setResizeWeight(0.3D);
        this.setBorder(javax.swing.BorderFactory.createEtchedBorder(javax.swing.border.EtchedBorder.LOWERED));
        this.setLeftComponent(getJScrollPane());

    }
1166622
private void initialize() {
        this.setLayout(new BorderLayout());
        this.setName(Constant.messages.getString("output.panel.title"));	// ZAP: i18n
	    if (Model.getSingleton().getOptionsParam().getViewParam().getWmUiHandlingOption() == 0) {
	    	this.setSize(243, 119);
	    }
        // ZAP: Added Output (doc) icon
		this.setIcon(new ImageIcon(OutputPanel.class.getResource("/resource/icon/16/172.png")));	// 'doc' icon
		this.setDefaultAccelerator(View.getSingleton().getMenuShortcutKeyStroke(KeyEvent.VK_O, KeyEvent.SHIFT_DOWN_MASK, false));
		this.setMnemonic(Constant.messages.getChar("output.panel.mnemonic"));

        this.add(getMainPanel(), BorderLayout.CENTER);
        this.setShowByDefault(true);
	}
1232986
private void init() {
        if (initialized.compareAndSet(false, true)) {
            final RowSorter<? extends TableModel> rowSorter = table.getRowSorter();
            rowSorter.toggleSortOrder(1); // sort by date
            rowSorter.toggleSortOrder(1); // descending
            final TableColumnModel columnModel = table.getColumnModel();
            columnModel.getColumn(1).setCellRenderer(dateRenderer);
            columnModel.getColumn(2).setCellRenderer(sizeRenderer);
        }
    }
1157995
public void init(int iMaxLength, boolean bAlignRight)
    {
        this.setColumns(iMaxLength);
        this.setBorder(null);
        if (bAlignRight)
            this.setHorizontalAlignment(JTextField.RIGHT);
    }
497951
@SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        stateTextLabel = new javax.swing.JLabel();

        addComponentListener(new java.awt.event.ComponentAdapter() {
            public void componentResized(java.awt.event.ComponentEvent evt) {
                formComponentResized(evt);
            }
        });

        stateTextLabel.setBackground(new java.awt.Color(238, 38, 238));
        stateTextLabel.setForeground(new java.awt.Color(255, 255, 255));
        stateTextLabel.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        stateTextLabel.setText("Loading");
        stateTextLabel.setVerticalAlignment(javax.swing.SwingConstants.TOP);
        stateTextLabel.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(stateTextLabel, javax.swing.GroupLayout.DEFAULT_SIZE, 396, Short.MAX_VALUE)
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap(167, Short.MAX_VALUE)
                .addComponent(stateTextLabel, javax.swing.GroupLayout.DEFAULT_SIZE, 121, Short.MAX_VALUE)
                .addContainerGap())
        );
    }