TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Use native context menus on Mac OS

587 点作者 reid将近 4 年前

31 条评论

jaas将近 4 年前
As someone who used to be involved in the decision to not implement native context menus, and did a bunch of work on the non-native ones, I want to try to explain why this took a long time.<p>It has nothing to do with engineering resources, and we always <i>wanted</i> native context menus, but they were not customizable enough to meet the perceived needs of web, XUL, and extension developers at the time. People expected to be able to change colors and layout with CSS, for example. The native APIs put heavy limitations on what you could do with a native context menu and it was just not compatible with the expectations of people building against the rendering engine at the time.<p>There was some discussion of switching back and forth between native and non-native menus based on styling, but that got complicated quickly and it wasn&#x27;t thought to be worthwhile.<p>It sounds like perceived needs have changed, and maybe the native APIs allow for bit more flexibility now. Glad it&#x27;s happening, excited to see how well it works!
评论 #27277841 未加载
评论 #27277885 未加载
评论 #27276749 未加载
评论 #27285678 未加载
评论 #27283707 未加载
评论 #27288470 未加载
dijit将近 4 年前
The common practice now is to &quot;close stale issues&quot;, which was discussed recently, though I can&#x27;t find the thread.<p>It&#x27;s nice to see the inverse of that, I doubt anyone would have replied every 90 days for 21 years.
评论 #27274146 未加载
评论 #27274159 未加载
评论 #27274386 未加载
评论 #27274376 未加载
评论 #27274157 未加载
评论 #27274162 未加载
satysin将近 4 年前
Wow finally! I have to admit while I love Firefox using it on macOS just <i>feels</i> crappy as it is so out of place. I am a huge user of the macOS &quot;Look Up&quot; content menu feature and it being missing in Firefox always frustrates me.<p>As silly as it sounds this might just be enough to get me to use Firefox as my main browser on macOS. I have played around with Nightly recently and love the new UI design. Can&#x27;t wait for this to hit release.
评论 #27275381 未加载
评论 #27275363 未加载
评论 #27275236 未加载
评论 #27276191 未加载
mtlynch将近 4 年前
This is a fun comment:<p>&gt;<i>Blake Ross</i><p>&gt;<i>Comment 5 • 21 years ago</i><p>&gt;<i>How easy&#x2F;hard would this be?</i><p>Blake Ross[0] was 15 years old at the time of that comment. It was two years before he, Dave Hyatt, and Joe Hewitt published the first version of Firefox.<p>[0] <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Blake_Ross" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Blake_Ross</a>
评论 #27275865 未加载
评论 #27280327 未加载
mhd将近 4 年前
Ah, &quot;native&quot; and &quot;firefox&quot; really makes me miss Camino, which was a pretty great mix between OS X standard UI features and the FF rendering engine. But apparently keeping that up to speed with Firefox main releases was way too much effort (probably one of the reasons why there are plenty of webkit&#x2F;chrome shells and almost no Firefox ones).
评论 #27277991 未加载
qalmakka将近 4 年前
Wow, that issue is older than OS X itself, which I assume it means it originally referred to Classic Mac OS. It&#x27;s nice to see it tackled after all this time, AFAIK Mozilla doesn&#x27;t even support XUL anymore.
评论 #27275411 未加载
slver将近 4 年前
&quot;Hey, why not use native context menus?&quot;<p>&quot;I can&#x27;t argue, but it&#x27;s a time thing.&quot;<p>21 years later...<p>&quot;Fixed.&quot;
评论 #27274065 未加载
评论 #27275487 未加载
abdusco将近 4 年前
One thing that bugs me is that on macOS access keys[0] are not underlined. This means I can&#x27;t pick an action with the keyboard and have to use the trackpad. Anyone know how I can enable it &#x2F; if that&#x27;s even possible?<p>As a recent Mac user, I don&#x27;t know if this is a mac thing, but I hate not being able to use the keyboard to navigate around the UI. Although the trackpad is nice, it can&#x27;t beat the precision of the keyboard. I can&#x27;t focus the menu bar, trigger a context menu with the keyboard, tab around panels and buttons. It&#x27;s an accessibility nightmare.<p>[0]: <a href="https:&#x2F;&#x2F;docs.microsoft.com&#x2F;en-us&#x2F;windows&#x2F;win32&#x2F;uxguide&#x2F;images&#x2F;inter-keyboard-image3.png" rel="nofollow">https:&#x2F;&#x2F;docs.microsoft.com&#x2F;en-us&#x2F;windows&#x2F;win32&#x2F;uxguide&#x2F;image...</a>
评论 #27274607 未加载
评论 #27274406 未加载
评论 #27278460 未加载
评论 #27274428 未加载
评论 #27276622 未加载
评论 #27275572 未加载
评论 #27275892 未加载
评论 #27280604 未加载
评论 #27288552 未加载
评论 #27286825 未加载
nyx将近 4 年前
Leaves me feeling a little contemplative... will the stuff I&#x27;m logging in my project&#x27;s issue tracker still exist in 2040? Will my project be relevant, or even remembered? Is the company we&#x27;re working for even going to be around?
评论 #27274014 未加载
评论 #27274279 未加载
评论 #27274023 未加载
评论 #27273946 未加载
jez将近 4 年前
Just downloaded the beta. I was hoping this meant that right clicking on selected text in Firefox on macOS would let me look up the word in the macOS system dictionary (e.g., in both Safari and Chrome, if you right click on a selected word, the first result in the context menu is `Look up &quot;&lt;word&gt;&quot;`).<p>It&#x27;s such a convenient way to learn new words (and even works across multiple languages). Alas. Maybe in a future update!<p>(Another, similar, gripe is that both Safari and Chrome, along with most other native macOS apps, will select the word under the cursor with just a right click—no need to even double click to select first and then right click. Firefox doesn&#x27;t do that.)
评论 #27275389 未加载
评论 #27274372 未加载
评论 #27274508 未加载
评论 #27276380 未加载
评论 #27274363 未加载
评论 #27274635 未加载
评论 #27274266 未加载
wodenokoto将近 4 年前
Not having the &quot;Look up ...&quot; available from the context menu is my biggest pet-peeve with Firefox on MacOS.<p>I know you can force-click on laptops, but, not everyone is on a laptop all the time, and force-clicking doesn&#x27;t allow you to choose the selection, which can be quite problematic for languages that doesn&#x27;t use spaces.
评论 #27274701 未加载
评论 #27274444 未加载
fuzzy2将近 4 年前
Meanwhile, on Windows, there’s nothing left of the browser that looks native.
评论 #27274569 未加载
评论 #27274866 未加载
评论 #27274609 未加载
评论 #27274277 未加载
评论 #27274622 未加载
评论 #27276602 未加载
larrysalibra将近 4 年前
Now if only they’d use the macOS native print dialog like every other app. What ever possessed them to roll their own print dialog?
评论 #27273951 未加载
评论 #27274362 未加载
评论 #27273958 未加载
评论 #27273928 未加载
评论 #27274309 未加载
was_a_dev将近 4 年前
A 21 year old bug. At that point the developer creating the fix could have been younger than the open issue itself
评论 #27275367 未加载
pjc50将近 4 年前
Every now and again I get an email about a bug I commented on sixteen years ago that was opened 21 years ago: <a href="https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=57342" rel="nofollow">https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=57342</a><p>It&#x27;s kind of nice to see that they will, eventually, get round to issues like this.
评论 #27276193 未加载
beltsazar将近 4 年前
And it breaks my workflow..<p>When I read a webpage, I often select some words (technical terms, movie names, etc), right-click, and press &quot;S&quot; in the keyboard for quickly googling the words. I tried it in Firefox Developer Edition (equivalent to Firefox Beta) which already has native context menus, and it didn&#x27;t work.<p>Can&#x27;t believe this happens to me: <a href="https:&#x2F;&#x2F;xkcd.com&#x2F;1172&#x2F;" rel="nofollow">https:&#x2F;&#x2F;xkcd.com&#x2F;1172&#x2F;</a>
评论 #27280735 未加载
thih9将近 4 年前
Impressive! I like how this makes the browser&#x27;s UI simpler and more predictable.<p>Also, this is especially useful for people using dark mode, since native context menus match that setting.
singhkays将近 4 年前
One of the problems I&#x27;ve found with native context&#x2F;drop down menus is that when you&#x27;re sharing a specific window on Zoom, the context menus don&#x27;t show up on the video.<p>You have to share your entire screen to show someone all the available options in the context&#x2F;drop-down menu.
评论 #27274085 未加载
jenshk将近 4 年前
But but.... There is no data. There is only XUL
pwdisswordfish8将近 4 年前
The cynic in me thinks this just happened because of a code rewrite they wanted to do anyway for reasons unrelated to this bug report. It’s just a coincidence that the rewrite allowed them to close it. (The initial report mentioned XUL, which if I understand correctly, isn’t even used in Firefox any more.) This is hardly some kind of a commendable instance of listening to your users.<p>I mean, compare it to this bug report:<p><a href="https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=309807" rel="nofollow">https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=309807</a><p>First the response was ‘just use an extension’. I did that happily, until the extension API was neutered, making the extension non-functional. When people brought that up, Mozilla closed comments on the bug report. Now it is closed as WONTFIX with this laughable excuse:<p>&gt; Extension APIs (which I know aren&#x27;t yet available) would be the solution for implementing this if there is enough demand.<p>Meanwhile, Chromium had this from day one. It works a bit differently now, but it’s still there, I just checked. Doable? Perfectly doable.
fen4o将近 4 年前
Better late than never
tobiasu将近 4 年前
Related: Can anyone share the google search to find instructions how to get started with firefox development?<p>Have they removed it all? I can find old stuff in the archived github repo, but that&#x27;s about it. What&#x27;s the official entry point?
评论 #27275563 未加载
millerm将近 4 年前
I’d love to have the “Look up” option on the menu. Every time I right click I am again reminded of its absence. So, hopefully “soon”.
xfz将近 4 年前
I just hope there&#x27;s no regression. :)
mariusmarais将近 4 年前
Hope it wasn&#x27;t P1 for the full 21 years.<p>Edit: Bumped from P3 -&gt; P1 3 months ago :)
megamix将近 4 年前
Some things are not meant to be fixed hehe. I love old bugs!
sbahr001将近 4 年前
That is a very long bug, 21 years in the making lol
marban将近 4 年前
About that color management thing...<p><a href="https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=455077" rel="nofollow">https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=455077</a>
DonHopkins将近 4 年前
I have always wanted to implement pie menus as a Firefox or Chrome extension, but I&#x27;ve never been able to find a sufficient API that enables me to pop up a modal dialog window at any place on the screen (specifically: centered on the current mouse cursor position, and in an operating system window that exists outside of the browser tab, overlapping all other windows). Or reshape it to any shape (or simply respect the alpha channel of the document and not show any chrome), so I can make a round or arbitrarily shaped window shrink wrapped to the items.<p><a href="https:&#x2F;&#x2F;developer.chrome.com&#x2F;docs&#x2F;extensions&#x2F;reference&#x2F;windows&#x2F;#type-CreateType" rel="nofollow">https:&#x2F;&#x2F;developer.chrome.com&#x2F;docs&#x2F;extensions&#x2F;reference&#x2F;windo...</a><p>Is there a way with that (or any other) API to pop up and precisely measure and position an arbitrarily shaped (alpha channeled) window, without any other chrome or window frames? And then globally capture and track mouse and keyboard events?<p>Does anyone know if there&#x27;s now a way for a browser extension to do that in any browser? Or would it require hacking platform specific C++ operating system code?<p>Here&#x27;s a demo of an ancient implementation of pie menus I made for ActiveX around 1997, that shows pie menus with arbitrarily shaped windows:<p>ActiveX Pie Menus: Demo of the free ActiveX Pie Menu Control, developed and demonstrated by Don Hopkins.<p><a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=nnC8x9x3Xag" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=nnC8x9x3Xag</a><p>ActiveX Pie Menus doc, examples, sources, etc:<p><a href="https:&#x2F;&#x2F;www.donhopkins.com&#x2F;home&#x2F;catalog&#x2F;piemenus&#x2F;ActiveXPieMenus.html" rel="nofollow">https:&#x2F;&#x2F;www.donhopkins.com&#x2F;home&#x2F;catalog&#x2F;piemenus&#x2F;ActiveXPieM...</a><p><a href="https:&#x2F;&#x2F;www.donhopkins.com&#x2F;home&#x2F;catalog&#x2F;piemenus&#x2F;PieMenuDescription.html" rel="nofollow">https:&#x2F;&#x2F;www.donhopkins.com&#x2F;home&#x2F;catalog&#x2F;piemenus&#x2F;PieMenuDesc...</a><p>I did all the drawing with Win32 calls, so you could configure the fonts and colors and sizes and window shapes and styles, but you couldn&#x27;t style everything arbitrarily with css, embed arbitrary web content, or anything nice like that.<p>At the end of the demo video, I concluded that:<p>&gt;I ran up into a wall of complexity with this ActiveX control, in that I wanted to be able to have as the menu items animated gifs, mpeg movies, fonts with nice attributes, and things like that.<p>&gt;So the first thought was &quot;well let&#x27;s just put a whole web browser in every item!&quot;<p>&gt;But that was a little heavy-handed. So instead, I put the pie menus into the web browser as a Dynamic HTML Component. Which I&#x27;ll show next.<p>Of course it makes a lot more sense to draw and style the pie menus with the browser&#x27;s renderer, but I still want the best of both worlds, where I can pop browser-drawn pie menus in arbitrarily shaped and positioned operating system windows, and track the mouse globally (capturing the mouse and keyboard events and receiving mouse motion and up and key events outside the window, to pop up and track sub-menus properly).<p>JavaScript Pie Menus: Pie menus for JavaScript on Internet Explorer version 5, configured in XML, rendered with dynamic HTML, by Don Hopkins:<p><a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=R5k4gJK-aWw&amp;ab_channel=DonHopkinsDonHopkins" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=R5k4gJK-aWw&amp;ab_channel=DonHo...</a>
评论 #27276326 未加载
评论 #27278445 未加载
评论 #27282560 未加载
kome将近 4 年前
when will be the turn for <a href="https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=734643" rel="nofollow">https:&#x2F;&#x2F;bugzilla.mozilla.org&#x2F;show_bug.cgi?id=734643</a> ? 9 years already.<p>I wish I could donate just to fix this bug for everybody.
modeitsch将近 4 年前
But I don’t use them any more only brave