Opened 10 years ago
Closed 10 years ago
#12417 closed defect (fixed)
[patch] mapmodes did not listen to preferences change
Reported by: | kolesar | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | 16.02 |
Component: | Core | Version: | |
Keywords: | Cc: |
Description
Some mapmodes cached preferences by their readPreferences() method and did not refresh them later. Some of them called this method on entering mode but it is not enough. When a user changes a setting of a tool it is usually active already. Therefore mapmodes should update their cached preferences on preference change.
I have modified MapMode to be PreferenceChangedListener. Also modified readPreferences() method in the affected mapmodes from private to protected for overriding.
Splinex plugin was also affected, attached a separate patchfile.
Attachments (3)
Change History (8)
by , 10 years ago
Attachment: | MapModePreferenceChangedListener.patch added |
---|
by , 10 years ago
Attachment: | SplinexMapModeOverride.patch added |
---|
comment:1 by , 10 years ago
comment:3 by , 10 years ago
This action opens the relation that was closed last time. It works as an undo for closing relation editor. Similar to History / Recently closed windows / <first entry> Ctrl+Shift+T
in web browsers.
I did not want to complicate existing Edit button and popping up last closed seemed to be a good trade-off. I will update this patch to remember a list of recently closed relations and shortcut will pop up first entry. This way shortcut can be pressed repeatedly, similar to browser tabs.
by , 10 years ago
Attachment: | MapModePreferenceChangedListener.2.patch added |
---|
comment:4 by , 10 years ago
Milestone: | → 16.02 |
---|
The inactive mapmodes need not be on alert all the time. Why not register
PreferenceChangedListener
& firereadPreferences
onenterMode
and unregister onexitMode
?