]> khamidou — GitHub mirrors - electron.git/commitdiff
views: Fix "visible" not working in menu bar, closes #825
authorCheng Zhao <zcbenz@gmail.com>
Sun, 16 Nov 2014 08:01:33 +0000 (16:01 +0800)
committerCheng Zhao <zcbenz@gmail.com>
Sun, 16 Nov 2014 08:01:33 +0000 (16:01 +0800)
atom/browser/ui/views/menu_delegate.cc
atom/browser/ui/views/menu_delegate.h

index eed5af764e84997c610305ac7f0a656efa4e1e75..84c35d9cd14d3d9fc68d6c741dc1ee1e6ba84828 100644 (file)
@@ -90,6 +90,10 @@ bool MenuDelegate::IsCommandEnabled(int id) const {
   return delegate()->IsCommandEnabled(id);
 }
 
+bool MenuDelegate::IsCommandVisible(int id) const {
+  return delegate()->IsCommandVisible(id);
+}
+
 bool MenuDelegate::IsItemChecked(int id) const {
   return delegate()->IsItemChecked(id);
 }
index 4f84d166db6a4ddd6f2ec1a1b2eff5ab33c18341..a837e5d53eb2799eda5481f7245ac31c2daf6daf 100644 (file)
@@ -38,6 +38,7 @@ class MenuDelegate : public views::MenuDelegate {
   base::string16 GetLabel(int id) const override;
   const gfx::FontList* GetLabelFontList(int id) const override;
   bool IsCommandEnabled(int id) const override;
+  bool IsCommandVisible(int id) const override;
   bool IsItemChecked(int id) const override;
   void SelectionChanged(views::MenuItemView* menu) override;
   void WillShowMenu(views::MenuItemView* menu) override;