Messages sent while editing group
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Messages sent while editing group
I have mouseEnter and mouseLeave handlers in my movie script that set the text of a field. When I try to edit a group that doesn't include the field in question those handlers generate an error because, apparently, when in group edit mode Livecode forgets about other objects not in that group. I can neutralize those handlers in advance by commenting them out, but that's rather a pain in the neck.
As with many of my posts I suspect the solution is simple, but I have not been able to find it.
Thanks!
As with many of my posts I suspect the solution is simple, but I have not been able to find it.
Thanks!
Re: Messages sent while editing group
Unfortunately this is a known "feature".
I definitively consider this a bug, edit mode should not do this, but there was a discussion on the mailinglist
some time ago with the result that this is considered to be a feature...
Sorry for the bad news.
I definitively consider this a bug, edit mode should not do this, but there was a discussion on the mailinglist
some time ago with the result that this is considered to be a feature...
Sorry for the bad news.
Re: Messages sent while editing group
Bad news, indeed, but thanks for the quick answer, Klaus.
Bruce
Bruce
-
- VIP Livecode Opensource Backer
- Posts: 9670
- Joined: Wed May 06, 2009 2:28 pm
- Location: New York, NY
Re: Messages sent while editing group
Hi.
Can you please tell me in different words what you are seeing? I understand you have certain handlers, but also that you say "edit a group that doesn't include the field in question".
You are in edit mode. What do those handlers have to do with the editing process? They cannot fire while editing.
I am missing it.
Craig
Can you please tell me in different words what you are seeing? I understand you have certain handlers, but also that you say "edit a group that doesn't include the field in question".
You are in edit mode. What do those handlers have to do with the editing process? They cannot fire while editing.
I am missing it.
Craig
Re: Messages sent while editing group
Re: Messages sent while editing group
A lot of this is confusing, especially to newcomers.Klaus wrote: ↑Tue Jan 03, 2023 11:03 amHi Craig,FYI: https://quality.livecode.com/show_bug.cgi?id=23143
Best
Klaus
The perceptual difficulty arises from the fact that newcomers used to other environments expect to have an 'IDE' version of an app for design/coding purposes, which then can (usually by compilation) be made to run as an app - therefore there are 2 distinct conceptual modes - a 'design' mode and a 'runtime' mode.
The conceptual difficulty arises from the fact that in LC you are presented with a 'design' mode and a 'runtime' mode in the form of a tool which you toggle, but that is complete fiction
This lie is clearly fostered by LC itself to present an 'easy' interface to newcomers, while old-timers are wiser than than that.
Both tools run in both IDE and standalone. It was only very recently I discovered that actually 'pointer tool' - which in my mind had become the 'IDE design tool' based on LC's own innumerable tutorials actually runs just fine in standalones, and actually has a clear role in standalone apps (even though I managed to break this by adding my own code to controls )
So the concept of 'runs in browse tool' and 'runs in pointer tool' are not synonymous for runs in app & runs in IDE. Hence many messages and reacting to mouse events is a feature not a bug; but I would still argue these should not work while designing the app in the IDE.
In my mind, instead of the artificial distinction between tools to discern if designing or testing an app, there should be an additional switch which denotes exactly that - design mode and runtime mode (instead of which tool is selected, since both tools work in both circumstances).
My $0.02 anyway...
Re: Messages sent while editing group
Replying to Craig (dunbarx): They do fire. They fire while in edit mode, not running mode, in the development (Livecode) environment. As far as I can tell it only happens to me when I edit a group. When I move the pointer to edit a group member a mouseEnter or mouseLeave handler pops up in debug mode with an error "no such object."
Having said that I seem to have solved the problem by making the mouse handlers more restrictive (better "if" conditions). So, all's well that ends well.
Having said that I seem to have solved the problem by making the mouse handlers more restrictive (better "if" conditions). So, all's well that ends well.
-
- VIP Livecode Opensource Backer
- Posts: 9670
- Joined: Wed May 06, 2009 2:28 pm
- Location: New York, NY
Re: Messages sent while editing group
Klaus, Stam and bd525.
As usual, it is my brain that is the problem. I even have posts here dealing with those two messages firing in edit mode.
I just did not understand the question as posted.
Craig
As usual, it is my brain that is the problem. I even have posts here dealing with those two messages firing in edit mode.
I just did not understand the question as posted.
Craig