mirror of https://github.com/cy384/ssheven.git
add edit menu
This commit is contained in:
parent
18fb41d338
commit
a9fbb1092a
|
@ -53,7 +53,8 @@
|
||||||
|
|
||||||
/* menus */
|
/* menus */
|
||||||
#define SSHEVEN_MBAR 128
|
#define SSHEVEN_MBAR 128
|
||||||
#define MENU_APPLE 128
|
#define MENU_APPLE 128
|
||||||
#define MENU_FILE 129
|
#define MENU_FILE 129
|
||||||
|
#define MENU_EDIT 130
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -640,6 +640,11 @@ int main(int argc, char** argv)
|
||||||
void* menu = GetNewMBar(SSHEVEN_MBAR);
|
void* menu = GetNewMBar(SSHEVEN_MBAR);
|
||||||
SetMenuBar(menu);
|
SetMenuBar(menu);
|
||||||
AppendResMenu(GetMenuHandle(MENU_APPLE), 'DRVR');
|
AppendResMenu(GetMenuHandle(MENU_APPLE), 'DRVR');
|
||||||
|
|
||||||
|
// disable everything in the edit menu until we implement it
|
||||||
|
menu = GetMenuHandle(MENU_EDIT);
|
||||||
|
DisableItem(menu, 0);
|
||||||
|
|
||||||
DrawMenuBar();
|
DrawMenuBar();
|
||||||
|
|
||||||
console_setup();
|
console_setup();
|
||||||
|
|
19
ssheven.r
19
ssheven.r
|
@ -235,7 +235,7 @@ resource 'BNDL' (128, purgeable) {
|
||||||
|
|
||||||
resource 'MBAR' (SSHEVEN_MBAR, preload)
|
resource 'MBAR' (SSHEVEN_MBAR, preload)
|
||||||
{
|
{
|
||||||
{ MENU_APPLE, MENU_FILE };
|
{ MENU_APPLE, MENU_FILE, MENU_EDIT };
|
||||||
};
|
};
|
||||||
|
|
||||||
resource 'MENU' (MENU_APPLE) {
|
resource 'MENU' (MENU_APPLE) {
|
||||||
|
@ -257,6 +257,23 @@ resource 'MENU' (MENU_FILE) {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
resource 'MENU' (MENU_EDIT) {
|
||||||
|
MENU_EDIT, textMenuProc;
|
||||||
|
allEnabled, enabled;
|
||||||
|
"Edit";
|
||||||
|
{
|
||||||
|
"Undo", noIcon, "Z", noMark, plain;
|
||||||
|
"-", noIcon, noKey, noMark, plain;
|
||||||
|
"Cut", noIcon, "X", noMark, plain;
|
||||||
|
"Copy", noIcon, "C", noMark, plain;
|
||||||
|
"Paste", noIcon, "V", noMark, plain;
|
||||||
|
"Clear", noIcon, noKey, noMark, plain;
|
||||||
|
"Select All", noIcon, "A", noMark, plain;
|
||||||
|
"-", noIcon, noKey, noMark, plain;
|
||||||
|
"Show Clipboard", noIcon, noKey, noMark, plain;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
#include "Icons.r"
|
#include "Icons.r"
|
||||||
|
|
||||||
/* use this regex to get rid of data comments: " \/\*[^\*]*\*\/" */
|
/* use this regex to get rid of data comments: " \/\*[^\*]*\*\/" */
|
||||||
|
|
Loading…
Reference in New Issue