summaryrefslogtreecommitdiff
path: root/src/envshell.h
diff options
context:
space:
mode:
authorisanae <14251494+isanae@users.noreply.github.com>2020-01-22 01:03:00 -0500
committerisanae <14251494+isanae@users.noreply.github.com>2020-02-04 03:33:21 -0500
commita7a406e5538b343d87b3221b13b7bf3503bbfd70 (patch)
tree0e4f5cc1bb25197bb6b7102016bfee09d6aceedb /src/envshell.h
parent0f6205bea500169b48b86e321d4d3f650603da2d (diff)
preparing for multiple origins shell menus
split exec() from createMenu()
Diffstat (limited to 'src/envshell.h')
-rw-r--r--src/envshell.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/envshell.h b/src/envshell.h
index 86d9b0fc..f25aeda7 100644
--- a/src/envshell.h
+++ b/src/envshell.h
@@ -12,10 +12,16 @@ class ShellMenu
{
public:
void addFile(QFileInfo fi);
+
void exec(QWidget* parent, const QPoint& pos);
+ HMENU getMenu();
private:
std::vector<QFileInfo> m_files;
+ COMPtr<IContextMenu> m_cm;
+ HMenuPtr m_menu;
+
+ void createMenu();
QMainWindow* getMainWindow(QWidget* w);
COMPtr<IShellItem> createShellItem(const std::wstring& path);
@@ -25,9 +31,10 @@ private:
COMPtr<IShellItemArray> createItemArray(std::vector<LPCITEMIDLIST>& idls);
COMPtr<IContextMenu> createContextMenu(IShellItemArray* array);
HMenuPtr createMenu(IContextMenu* cm);
+ HMenuPtr createDummyMenu(const QString& what);
+
int runMenu(QMainWindow* mw, IContextMenu* cm, HMENU menu, const QPoint& p);
void invoke(QMainWindow* mw, const QPoint& p, int cmd, IContextMenu* cm);
- void showDummyMenu(QMainWindow* mw, const QPoint& pos, const QString& what);
};
} // namespace