Changing a CALayer in a menu callback doesn't trigger re-draw / re-layout

This commit is contained in:
Mathieu Monney committed 2013-11-18 15:29:41 +01:00
1 parent 4a82dbc34d
commit 0cfb53cea4
1 file changed
+5
+5
View File
@@ -27,6 +27,7 @@
@import "CPKeyValueBinding.j"
@import "CPMenuItem.j"
@import "CALayer.j"
@global CPApp
@@ -999,6 +1000,10 @@ var _CPMenuBarVisible = NO,
// an additional mouse move after all this, but not in other browsers.
// This will be fixed correctly with the coming run loop changes.
[_CPDisplayServer run];
// If layers are updated within the menu callback, the re-draw & re-layout doesn't occur until a mouse move.
// We force the update here.
[CALayer runLoopUpdateLayers];
}
/* @ignore */