mirror of
https://github.com/ksherlock/dict.git
synced 2024-06-10 05:29:34 +00:00
minor tweaks.
This commit is contained in:
parent
91b9173244
commit
bab3dfc384
15
nda.c
15
nda.c
|
@ -302,7 +302,7 @@ pascal void DrawInfo(Rect *rect, const char *str, GrafPortPtr w) {
|
||||||
SetBackColor(0x0f);
|
SetBackColor(0x0f);
|
||||||
EraseRect(rect);
|
EraseRect(rect);
|
||||||
if (str) {
|
if (str) {
|
||||||
MoveTo(/*8, 22*/ rect->h1 + 2, rect->v1 + 2);
|
MoveTo(/*8, 22*/ rect->h1 + 10, rect->v1 + 9);
|
||||||
DrawString(str);
|
DrawString(str);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -311,6 +311,11 @@ void DrawWindow(void) { DrawControls(GetPort()); }
|
||||||
|
|
||||||
#pragma databank 0
|
#pragma databank 0
|
||||||
|
|
||||||
|
void MakeCtlTargetByID(GrafPortPtr window, Long resID) {
|
||||||
|
CtlRecHndl h = GetCtlHandleFromID(window, resID);
|
||||||
|
if (h) MakeThisCtlTarget(h);
|
||||||
|
}
|
||||||
|
|
||||||
void NDAInit(Word code) {
|
void NDAInit(Word code) {
|
||||||
if (code) {
|
if (code) {
|
||||||
MyWindow = NULL;
|
MyWindow = NULL;
|
||||||
|
@ -319,6 +324,7 @@ void NDAInit(Word code) {
|
||||||
|
|
||||||
MyID = MMStartUp();
|
MyID = MMStartUp();
|
||||||
ipid = 0;
|
ipid = 0;
|
||||||
|
st = st_none;
|
||||||
} else {
|
} else {
|
||||||
if (ToolsLoaded)
|
if (ToolsLoaded)
|
||||||
NDAShutDownTools(&ss);
|
NDAShutDownTools(&ss);
|
||||||
|
@ -365,12 +371,19 @@ GrafPortPtr NDAOpen(void) {
|
||||||
rWindParam1);
|
rWindParam1);
|
||||||
|
|
||||||
SetInfoDraw(DrawInfo, MyWindow);
|
SetInfoDraw(DrawInfo, MyWindow);
|
||||||
|
UpdateStatus(0);
|
||||||
|
|
||||||
AcceptRequests(ReqName, MyID, &HandleRequest);
|
AcceptRequests(ReqName, MyID, &HandleRequest);
|
||||||
|
|
||||||
|
|
||||||
|
MakeCtlTargetByID(MyWindow, rCtrlLE);
|
||||||
|
|
||||||
SetSysWindow(MyWindow);
|
SetSysWindow(MyWindow);
|
||||||
ShowWindow(MyWindow);
|
ShowWindow(MyWindow);
|
||||||
SelectWindow(MyWindow);
|
SelectWindow(MyWindow);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
ConnectionInit(&connection, MyID, MarinettiCallback);
|
ConnectionInit(&connection, MyID, MarinettiCallback);
|
||||||
|
|
||||||
NDAResourceRestore(&resInfo);
|
NDAResourceRestore(&resInfo);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user