コード例 #1
0
 /** Creates a new page of the given type with the given code */
 protected Editor createPage(String _type, String _name, String _code) {
   Editor page = new CodeEditor(ejs, this);
   page.setName(_name);
   if (_code != null) page.readString(_code);
   else page.clear();
   return page;
 }
コード例 #2
0
 private void renameCurrentPage(String _name) {
   int index = tabbedPanel.getSelectedIndex();
   if (index < 0) return;
   _name = getUniqueName(_name); // Gonzalo 070128
   tabbedPanel.setTitleAt(index, _name);
   Editor page = pageList.get(index);
   page.setName(_name);
   if (!page.isActive()) tabbedPanel.setTitleAt(index, page.getName() + " (D)");
   changed = true;
 }