Commit ee21e95d authored by Robert Sprowson's avatar Robert Sprowson

Colour picker help made more helpful.

Previously, the help requests would end up in the background event handler which didn't look at the window handle and would just return "This is paint" even if the handle was that of the colour picker dialogue.
Also now passes documented 0x80000000 and 0x7FFFFFFF on opening rather than zero.

Version 2.07. Tagged as 'Paint-2_07'
parent ecdac85b
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "2.06"
Module_Version SETA 206
Module_MajorVersion SETS "2.07"
Module_Version SETA 207
Module_MinorVersion SETS ""
Module_Date SETS "07 Dec 2010"
Module_ApplicationDate SETS "07-Dec-10"
Module_Date SETS "12 Dec 2010"
Module_ApplicationDate SETS "12-Dec-10"
Module_ComponentName SETS "Paint"
Module_ComponentPath SETS "castle/RiscOS/Sources/Apps/Paint"
Module_FullVersion SETS "2.06"
Module_HelpVersion SETS "2.06 (07 Dec 2010)"
Module_FullVersion SETS "2.07"
Module_HelpVersion SETS "2.07 (12 Dec 2010)"
END
/* (2.06)
/* (2.07)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 2.06
#define Module_MajorVersion_CMHG 2.07
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 07 Dec 2010
#define Module_Date_CMHG 12 Dec 2010
#define Module_MajorVersion "2.06"
#define Module_Version 206
#define Module_MajorVersion "2.07"
#define Module_Version 207
#define Module_MinorVersion ""
#define Module_Date "07 Dec 2010"
#define Module_Date "12 Dec 2010"
#define Module_ApplicationDate "07-Dec-10"
#define Module_ApplicationDate "12-Dec-10"
#define Module_ComponentName "Paint"
#define Module_ComponentPath "castle/RiscOS/Sources/Apps/Paint"
#define Module_FullVersion "2.06"
#define Module_HelpVersion "2.06 (07 Dec 2010)"
#define Module_LibraryVersionInfo "2:6"
#define Module_FullVersion "2.07"
#define Module_HelpVersion "2.07 (12 Dec 2010)"
#define Module_LibraryVersionInfo "2:7"
......@@ -532,13 +532,12 @@ void colours_create_window (main_sprite *sprite)
(psprite_hasmask (sprite)?
colourpicker_DIALOGUE_OFFERS_TRANSPARENT: 0) |
(sprite->gcol == nc? colourpicker_DIALOGUE_TRANSPARENT: 0) |
colourpicker_DIALOGUE_TYPE_CLICK <<
colourpicker_DIALOGUE_TYPE_SHIFT;
(colourpicker_DIALOGUE_TYPE_CLICK << colourpicker_DIALOGUE_TYPE_SHIFT);
ftracef1 ("flags set to 0x%X\n", dialogue.flags);
dialogue.title = sprite->colourtitle;
dialogue.visible.x0 = sprite_redraw_str.box.x1;
dialogue.visible.y0 = 0;
dialogue.visible.x1 = 0;
dialogue.visible.y0 = (int)0x80000000;
dialogue.visible.x1 = 0x7FFFFFFF;
dialogue.visible.y1 = sprite_w_state.o.box.y1;
dialogue.xscroll = 0;
dialogue.yscroll = 0;
......
......@@ -3070,9 +3070,23 @@ static void Background_Events (wimp_eventstr *e, void *handle)
break;
case wimp_MHELPREQUEST:
{ main_window *window;
ftracef0 ("Help request on icon\n");
e->data.msg.data.helprequest.m.i = 0;
main_help_message ("PntH5", e);
/*Look to see if this is a request to an adopted colour picker
window, if it's not just give generic 'This is paint' help */
for (window = main_windows; window != NULL; window = window->link)
if (window->tag == main_window_is_sprite)
{ if (window->data->sprite.sprite->colourhandle == e->data.msg.data.helprequest.m.w)
{ os_swix2 (ColourPicker_HelpReply, 0, &e->data);
break;
}
}
if (window == NULL)
{ e->data.msg.data.helprequest.m.i = 0;
main_help_message ("PntH5", e);
}
}
break;
case wimp_SAVEDESK:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment