diff options
author | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:29:28 +0200 |
---|---|---|
committer | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:29:28 +0200 |
commit | 75c07011b7c4d06acd7b45dabdcd60ab9d80f385 (patch) | |
tree | 8853c3978dd152ef377e652239448b1352320206 /ui/custom_grid.h | |
parent | 5.22 (diff) | |
download | FreeFileSync-75c07011b7c4d06acd7b45dabdcd60ab9d80f385.tar.gz FreeFileSync-75c07011b7c4d06acd7b45dabdcd60ab9d80f385.tar.bz2 FreeFileSync-75c07011b7c4d06acd7b45dabdcd60ab9d80f385.zip |
5.23
Diffstat (limited to 'ui/custom_grid.h')
-rw-r--r-- | ui/custom_grid.h | 82 |
1 files changed, 0 insertions, 82 deletions
diff --git a/ui/custom_grid.h b/ui/custom_grid.h deleted file mode 100644 index 32beee01..00000000 --- a/ui/custom_grid.h +++ /dev/null @@ -1,82 +0,0 @@ -// ************************************************************************** -// * This file is part of the FreeFileSync project. It is distributed under * -// * GNU General Public License: http://www.gnu.org/licenses/gpl.html * -// * Copyright (C) Zenju (zenju AT gmx DOT de) - All Rights Reserved * -// ************************************************************************** - -#ifndef CUSTOMGRID_H_INCLUDED -#define CUSTOMGRID_H_INCLUDED - -#include <wx+/grid.h> -#include "grid_view.h" -#include "column_attr.h" -#include "../lib/icon_buffer.h" - -namespace zen -{ -//setup grid to show grid view within three components: -namespace gridview -{ -void init(Grid& gridLeft, Grid& gridCenter, Grid& gridRight, const std::shared_ptr<const GridView>& gridDataView); - -std::vector<Grid::ColumnAttribute> convertConfig(const std::vector<ColumnAttributeRim>& attribs); //+ make consistent -std::vector<ColumnAttributeRim> convertConfig(const std::vector<Grid::ColumnAttribute>& attribs); // - -void highlightSyncAction(Grid& gridCenter, bool value); - -void setupIcons(Grid& gridLeft, Grid& gridCenter, Grid& gridRight, bool show, IconBuffer::IconSize sz); - -void clearSelection(Grid& gridLeft, Grid& gridCenter, Grid& gridRight); //clear all components -void refresh(Grid& gridLeft, Grid& gridCenter, Grid& gridRight); - -void setScrollMaster(Grid& grid); - -//mark rows selected in navigation/compressed tree and navigate to leading object -void setNavigationMarker(Grid& gridLeft, - hash_set<const FileSystemObject*>&& markedFilesAndLinks,//mark files/symlinks directly within a container - hash_set<const HierarchyObject*>&& markedContainer); //mark full container including child-objects -} - -wxBitmap getSyncOpImage(SyncOperation syncOp); -wxBitmap getCmpResultImage(CompareFilesResult cmpResult); - - -//---------- custom events for middle grid ---------- - -//(UN-)CHECKING ROWS FROM SYNCHRONIZATION -extern const wxEventType EVENT_GRID_CHECK_ROWS; -//SELECTING SYNC DIRECTION -extern const wxEventType EVENT_GRID_SYNC_DIRECTION; - -struct CheckRowsEvent : public wxCommandEvent -{ - CheckRowsEvent(size_t rowFirst, size_t rowLast, bool setIncluded) : wxCommandEvent(EVENT_GRID_CHECK_ROWS), rowFirst_(rowFirst), rowLast_(rowLast), setIncluded_(setIncluded) { assert(rowFirst <= rowLast); } - virtual wxEvent* Clone() const { return new CheckRowsEvent(*this); } - - const size_t rowFirst_; //selected range: [rowFirst_, rowLast_) - const size_t rowLast_; //range is empty when clearing selection - const bool setIncluded_; -}; - - -struct SyncDirectionEvent : public wxCommandEvent -{ - SyncDirectionEvent(size_t rowFirst, size_t rowLast, SyncDirection direction) : wxCommandEvent(EVENT_GRID_SYNC_DIRECTION), rowFirst_(rowFirst), rowLast_(rowLast), direction_(direction) { assert(rowFirst <= rowLast); } - virtual wxEvent* Clone() const { return new SyncDirectionEvent(*this); } - - const size_t rowFirst_; //see CheckRowsEvent - const size_t rowLast_; // - const SyncDirection direction_; -}; - -typedef void (wxEvtHandler::*CheckRowsEventFunction)(CheckRowsEvent&); -typedef void (wxEvtHandler::*SyncDirectionEventFunction)(SyncDirectionEvent&); - -#define CheckRowsEventHandler(func) \ - (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(CheckRowsEventFunction, &func) - -#define SyncDirectionEventHandler(func) \ - (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(SyncDirectionEventFunction, &func) -} - -#endif // CUSTOMGRID_H_INCLUDED |