FIX: optimize media file panel

1. disable select when no file
2. disable batch edit button when no selection
3. hide batch edit when no file
4. delete/play/open_folder for downloaded file
5. hide type panel

Change-Id: Ida00da366a8f59b2c5028ddcf87e197c20a21e44
This commit is contained in:
chunmao.guo 2022-10-14 09:25:17 +08:00 committed by Lane.Wei
parent c2c7a6786d
commit 76d021ceaf
8 changed files with 117 additions and 32 deletions

View file

@ -18,6 +18,7 @@ using nlohmann::json;
wxDECLARE_EVENT(EVT_STATUS_CHANGED, wxCommandEvent);
wxDECLARE_EVENT(EVT_MODE_CHANGED, wxCommandEvent);
wxDECLARE_EVENT(EVT_FILE_CHANGED, wxCommandEvent);
wxDECLARE_EVENT(EVT_SELECT_CHANGED, wxCommandEvent);
wxDECLARE_EVENT(EVT_THUMBNAIL, wxCommandEvent);
wxDECLARE_EVENT(EVT_DOWNLOAD, wxCommandEvent);
@ -137,6 +138,8 @@ public:
void SelectAll(bool select);
size_t GetSelectCount() const;
void SetFocusRange(size_t start, size_t count);
File const &GetFile(size_t index);
@ -263,6 +266,7 @@ protected:
std::vector<size_t> m_group_month;
private:
size_t m_select_count = 0;
size_t m_lock_start = 0;
size_t m_lock_end = 0;
int m_task_flags = 0;