Skip to content

Close button on map custom exit dialog not cancelling line drawing#432

Merged
vadi2 merged 1 commit intoMudlet:release_30from
vadi2:(release_30)-fix-custom-lines-crash
Mar 23, 2017
Merged

Close button on map custom exit dialog not cancelling line drawing#432
vadi2 merged 1 commit intoMudlet:release_30from
vadi2:(release_30)-fix-custom-lines-crash

Conversation

@vadi2
Copy link
Copy Markdown
Member

@vadi2 vadi2 commented Mar 22, 2017

Cherry-picked commit that fixed a crash when opening the custom exit lines dialog (because the point was not initialised properly), and a case where if X was used to close the dialog drawing was still commenced.

Original message below:
As per http://bugs.launchpad.net/mudlet/+bug/1369041 the built-in dialog
button that some OS/Window systems provide did close the dialog but did not
cancel the custom line drawing process. This fixes the matter by
connecting the reject() signal that the button produces to code to clean
up.

During debugging this it became clear that: if the custom line dialog was
being displayed but before the user had selected the exit to draw the line
for, it was possible to click on the map and add points to create a line;
this would be for a custom line with an Empty exit name which should not be
permitted. To prevent this a flag "mDialogLock" was added to the class to
prevent the mouse events that would draw or modify a custom line from
proceeding until the custom line dialog had been used or cancelled.

Signed-off-by: Stephen Lyons slysven@virginmedia.com

(cherry picked from commit 07c6a3e)

…awing

As per http://bugs.launchpad.net/mudlet/+bug/1369041 the built-in dialog
button that some OS/Window systems provide did close the dialog but did not
cancel the custom line drawing process.  This fixes the matter by
connecting the reject() signal that the button produces to code to clean
up.

During debugging this it became clear that: if the custom line dialog was
being displayed but before the user had selected the exit to draw the line
for, it was possible to click on the map and add points to create a line;
this would be for a custom line with an Empty exit name which should not be
permitted.  To prevent this a flag "mDialogLock" was added to the class to
prevent the mouse events that would draw or modify a custom line from
proceeding until the custom line dialog had been used or cancelled.

Signed-off-by: Stephen Lyons <slysven@virginmedia.com>

(cherry picked from commit 07c6a3e)
@vadi2 vadi2 requested a review from SlySven March 22, 2017 19:08
@vadi2 vadi2 self-assigned this Mar 22, 2017
@vadi2
Copy link
Copy Markdown
Member Author

vadi2 commented Mar 22, 2017

Hopefully a big less merge conflicts to deal with in The Merge thanks to the resolutions done in this commit.

Copy link
Copy Markdown
Member

@SlySven SlySven left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like a good 🍒-pick does it do what it says on the tin for this branch? {If not I guess that would make it a 🍋-pick - leaving a sour taste behind - instead 🤣}

I'll assume that it works and thus give it approval.

@vadi2
Copy link
Copy Markdown
Member Author

vadi2 commented Mar 23, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants