On Sun, Feb 27, 2011 at 3:08 PM, RevList <[email protected]> wrote:
> I am building an app and want to control the enabling and disabling of > menu items based on where the cursor is. Mostly, I have no problem, > except when I am in a datagrid. > I have a datagrid that has only one editable column. When I double click > on that column on a row and get into that specific field for editing, I > want to enable some menu items (like Copy, paste). When I exit that > field, I want to disable them. > On other fields in the card, I do this on the OpenField and ExitField > handlers. > How do I do this in a Datagrid? > Might I suggest another approach? When the user clicks on a menu in your menubar a mouseDown message will be sent to the menubar group. In that mouseDown message Why not just use the selectedField and selectedChunk to determine if menus that target text should be enabled/disabled? This puts all of the checks in one place. The checks are really fast and won't cause a delay in the menu being shown to the user. -- Trevor DeVore Blue Mango Learning Systems ScreenSteps: http://www.screensteps.com LiveCode Resources for Developers: http://livecode.bluemangolearning.com _______________________________________________ use-livecode mailing list [email protected] Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
