summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXMenu.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2024-10-25 21:06:25 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2024-10-25 21:06:25 (GMT)
commit0d5336db012f45753abace489f18f0ca299c6961 (patch)
treeb1bf3280a9046df99226158978502eeb26f5b0a3 /macosx/tkMacOSXMenu.c
parente97381a6d921de403516d5b761539a450f4af83c (diff)
parent1320b8a2a9c1269a345d44d673a7a35707fbbe9c (diff)
downloadtk-core-tip-626.zip
tk-core-tip-626.tar.gz
tk-core-tip-626.tar.bz2
Merge 9.0core-tip-626
Diffstat (limited to 'macosx/tkMacOSXMenu.c')
-rw-r--r--macosx/tkMacOSXMenu.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/macosx/tkMacOSXMenu.c b/macosx/tkMacOSXMenu.c
index 1908bb9..ac8ec6f 100644
--- a/macosx/tkMacOSXMenu.c
+++ b/macosx/tkMacOSXMenu.c
@@ -960,8 +960,6 @@ TkpPostMenu(
}
realWin = Tk_Parent(realWin);
}
- NSWindow *win = [realWinView window];
- NSView *view = [win contentView];
NSMenu *menu = (NSMenu *) menuPtr->platformData;
NSInteger itemIndex = index;
NSInteger numItems = [menu numberOfItems];
@@ -971,8 +969,8 @@ TkpPostMenu(
inPostMenu = true;
result = TkPreprocessMenu(menuPtr);
if (result != TCL_OK) {
- inPostMenu = false;
- return result;
+ inPostMenu = false;
+ return result;
}
if (itemIndex >= numItems) {
itemIndex = numItems - 1;
@@ -991,8 +989,9 @@ TkpPostMenu(
}
[menu popUpMenuPositioningItem:item
- atLocation:[win tkConvertPointFromScreen:location]
- inView:view];
+ atLocation:location
+ inView:nil
+ appearance:realWinView.effectiveAppearance];
inPostMenu = false;
return TCL_OK;
}
@@ -1417,7 +1416,7 @@ TkpComputeStandardMenuGeometry(
}
menuSize = [(NSMenu *) menuPtr->platformData size];
- Tk_GetPixelsFromObj(NULL, menuPtr->tkwin, menuPtr->borderWidthPtr,
+ Tk_GetPixelsFromObj(NULL, menuPtr->tkwin, menuPtr->borderWidthObj,
&borderWidth);
Tk_GetPixelsFromObj(NULL, menuPtr->tkwin, menuPtr->activeBorderWidthPtr,
&activeBorderWidth);