mirror of
https://github.com/1dot13/source.git
synced 2026-09-02 14:36:06 +02:00
Merged New Inventory Project into main branch
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@1871 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+19
-19
@@ -2,8 +2,8 @@
|
||||
|
||||
#ifdef JA2EDITOR
|
||||
//popupmenu.h
|
||||
//Author: Kris Morness
|
||||
//Created: Sept 4, 1997
|
||||
//Author: Kris Morness
|
||||
//Created: Sept 4, 1997
|
||||
|
||||
#ifndef __POPUPMENU_H
|
||||
#define __POPUPMENU_H
|
||||
@@ -12,30 +12,30 @@
|
||||
POPUP MENU
|
||||
|
||||
DESIGN CONSIDERATIONS
|
||||
There is currently no support for nested popup menus. Let Kris know if
|
||||
There is currently no support for nested popup menus. Let Kris know if
|
||||
you need this.
|
||||
|
||||
USER INSTRUCTIONS
|
||||
The goal of this popup menu system is to create a quick and intuitive
|
||||
interface system which is functionally similar to Win95 and MacOS.
|
||||
interface system which is functionally similar to Win95 and MacOS.
|
||||
As soon as you click on a button which activates the popup menu, the user
|
||||
will choose a selection in one of three ways:
|
||||
|
||||
1) KEYBOARD - at anytime, the user can use the keyboard regardless of mouse
|
||||
mode. The up/down arrow keys will cycle through the choices and enter will
|
||||
accept the choice. ESC will cancel the menu without making a choice.
|
||||
mode. The up/down arrow keys will cycle through the choices and enter will
|
||||
accept the choice. ESC will cancel the menu without making a choice.
|
||||
2) When the mousedown event activates the menu, the user releases the mouse before
|
||||
entering the popup menu region. The menu mode will change and become persistant.
|
||||
Clicking on the hilighted item will close the popup and activate the choice.
|
||||
Clicking elsewhere, the popup will be closed without making a selection. This
|
||||
is functionally equivalent to Win95.
|
||||
entering the popup menu region. The menu mode will change and become persistant.
|
||||
Clicking on the hilighted item will close the popup and activate the choice.
|
||||
Clicking elsewhere, the popup will be closed without making a selection. This
|
||||
is functionally equivalent to Win95.
|
||||
3) When the mousedown event activates the menu, the user holds the mouse down and
|
||||
moves the cursor over the popup region. At this moment the menu becomes
|
||||
non-persistant and a choice is made by releasing the mouse. If the mouse is
|
||||
released on a highlighted choice, that choice is selected, otherwise the popup
|
||||
is cancelled. This is functionally equivalent to MacOS. The small diffence is
|
||||
that under Win95's standard convention, the release of the mouse outside of the
|
||||
region doesn't kill the menu, but in MacOS, it does.
|
||||
moves the cursor over the popup region. At this moment the menu becomes
|
||||
non-persistant and a choice is made by releasing the mouse. If the mouse is
|
||||
released on a highlighted choice, that choice is selected, otherwise the popup
|
||||
is cancelled. This is functionally equivalent to MacOS. The small diffence is
|
||||
that under Win95's standard convention, the release of the mouse outside of the
|
||||
region doesn't kill the menu, but in MacOS, it does.
|
||||
*/
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@ enum popupMenuIDs
|
||||
};
|
||||
|
||||
//The direction of the popup menu relative to the button
|
||||
//pressed to activate it or mouse position. In editor mode,
|
||||
//pressed to activate it or mouse position. In editor mode,
|
||||
//this will attempt to go up and to the right of the button.
|
||||
#define UPMASK 0x00
|
||||
#define DNMASK 0x10
|
||||
@@ -79,11 +79,11 @@ typedef struct currentPopupMenuInformation{
|
||||
UINT16 usFont;
|
||||
BOOLEAN fActive;
|
||||
BOOLEAN fUseKeyboardInfoUntilMouseMoves;
|
||||
UINT16 usLeft, usTop, usRight, usBottom; //popup region coords.
|
||||
UINT16 usLeft, usTop, usRight, usBottom; //popup region coords.
|
||||
UINT16 usLastMouseX, usLastMouseY;
|
||||
}CurrentPopupMenuInformation;
|
||||
|
||||
//A global var that keeps the popup menu information.
|
||||
//A global var that keeps the popup menu information.
|
||||
extern CurrentPopupMenuInformation gPopup;
|
||||
extern STR16 popupMenuStrings[5];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user