1 | public void setExtendedFrameTitle(String fname) {↵ | | 1 | public void setExtendedFrameTitle(String fname) {↵
|
2 | // file New operation may set to null, so just return app name↵ | | 2 | // file New operation may set to null, so just return app name↵
|
3 | if (fname == null) {↵ | | 3 | if (fname == null) {↵
|
4 | setTitle(DEFAULT_TITLE);↵ | | 4 | setTitle(DEFAULT_TITLE);↵
|
5 | return;↵ | | 5 | return;↵
|
6 | }↵ | | 6 | }↵
|
|
7 | // allow for windows / chars in filename↵ | | 7 | // allow for windows / chars in filename↵
|
8 | String temp = fname.replace('\\', '/'); // $NON-NLS-1$ // $NON-NLS-2$↵ | | 8 | String temp = fname.replace('\\', '/'); // $NON-NLS-1$ // $NON-NLS-2$↵
|
9 | String simpleName = temp.substring(temp.lastIndexOf("/") + 1);// $NON-NLS-1$↵ | | 9 | String simpleName = temp.substring(temp.lastIndexOf("/") + 1);// $NON-NLS-1$↵
|
10 | setTitle(simpleName + " (" + fname + ") - " + DEFAULT_TITLE); // $NON-NLS-1$ // $NON-NLS-2$↵ | | 10 | setTitle(simpleName + " (" + fname + ") - " + DEFAULT_TITLE); // $NON-NLS-1$ // $NON-NLS-2$↵
|
11 | | | 11 |
|