ASPiK SDK
imenubuilder.h
1 // This file is part of VSTGUI. It is subject to the license terms
2 // in the LICENSE file found in the top-level directory of this
3 // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE
4 
5 #pragma once
6 
7 #include "fwd.h"
8 #include "interface.h"
9 
10 //------------------------------------------------------------------------
11 namespace VSTGUI {
12 namespace Standalone {
13 
14 //------------------------------------------------------------------------
24 class IMenuBuilder : public Interface
25 {
26 public:
27  using SortFunction = std::function<bool (const UTF8String& lhs, const UTF8String& rhs)>;
28 
35  virtual bool showCommandGroupInMenu (const Interface& context,
36  const UTF8String& group) const = 0;
43  virtual bool showCommandInMenu (const Interface& context, const Command& cmd) const = 0;
50  virtual SortFunction getCommandGroupSortFunction (const Interface& context,
51  const UTF8String& group) const = 0;
58  virtual bool prependMenuSeparator (const Interface& context, const Command& cmd) const = 0;
59 };
60 
61 //------------------------------------------------------------------------
62 } // Standalone
63 } // VSTGUI
Definition: interface.h:13
virtual SortFunction getCommandGroupSortFunction(const Interface &context, const UTF8String &group) const =0
Definition: imenubuilder.h:24
virtual bool showCommandGroupInMenu(const Interface &context, const UTF8String &group) const =0
Definition: customcontrols.cpp:8
virtual bool showCommandInMenu(const Interface &context, const Command &cmd) const =0
virtual bool prependMenuSeparator(const Interface &context, const Command &cmd) const =0
Definition: icommand.h:24
holds an UTF8 encoded string and a platform representation of it
Definition: cstring.h:56