|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgui.GuiController
public class GuiController
This class is going to be used for implementing the main functions specified in Gui. Currently, the menubar functions are being implemented.
Field Summary | |
---|---|
static java.io.File |
activeFile
|
static java.io.File |
curDir
|
EditorPane |
editor
|
static java.io.File |
lastOpen
|
PFrame |
p
|
Constructor Summary | |
---|---|
GuiController()
|
Method Summary | |
---|---|
void |
copy(java.io.File src,
java.io.File dst)
This method copies source file to destination file. |
int |
newFileMenuItemPressed(PFrame callerFrame,
EditorPane editorPane,
java.lang.String filename,
java.lang.String filePath)
This method creates a new file dialog. |
int |
openMenuPressed(PFrame callerFrame,
EditorPane editorPane,
java.lang.String filePath)
This method creates an open file dialog. |
int |
saveAsMenuPressed(javax.swing.JFrame callerFrame,
EditorPane editorPane)
This method saves a file with a different file path. |
int |
saveMenuPressed(javax.swing.JFrame callerFrame,
EditorPane editorPane)
This method saves a modified file. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.io.File curDir
public static java.io.File lastOpen
public static java.io.File activeFile
public PFrame p
public EditorPane editor
Constructor Detail |
---|
public GuiController()
Method Detail |
---|
public int openMenuPressed(PFrame callerFrame, EditorPane editorPane, java.lang.String filePath)
public int saveMenuPressed(javax.swing.JFrame callerFrame, EditorPane editorPane)
public int newFileMenuItemPressed(PFrame callerFrame, EditorPane editorPane, java.lang.String filename, java.lang.String filePath)
public int saveAsMenuPressed(javax.swing.JFrame callerFrame, EditorPane editorPane)
public void copy(java.io.File src, java.io.File dst) throws java.io.IOException
src
- source filedst
- destination file
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |