From 5fd2ff2e287aed9b486f20e936dccf54d48747db Mon Sep 17 00:00:00 2001 From: King_DuckZ Date: Sun, 28 Mar 2021 00:59:35 +0100 Subject: [PATCH] Add menu and output box to generate the dele list --- close_64.png | Bin 0 -> 11070 bytes cog_64.png | Bin 0 -> 12269 bytes config.h.in | 1 + main.cpp | 5 ----- main_window.cpp | 45 ++++++++++++++++++++++++++++++++++++---- main_window.hpp | 15 ++++++++++++++ meson.build | 1 + notebook_tree.cpp | 4 ++++ notebook_tree.hpp | 1 + notebook_tree_model.hpp | 3 +++ 10 files changed, 66 insertions(+), 9 deletions(-) create mode 100644 close_64.png create mode 100644 cog_64.png diff --git a/close_64.png b/close_64.png new file mode 100644 index 0000000000000000000000000000000000000000..7bec782c9d4c2da4f01bbf78c994974c353189f4 GIT binary patch literal 11070 zcmeHtXH=8hwst5=uhKyYp@Z}qdWX7yx%q_9b z75^ly^k-Un()%`=C8*yo*O%hUj8DfbUhRtt{_(^)R9=-^_B;K)1Cc|`SMKbdbErVy zYohNn6MSB|y)_Ton)30Yn_ui-#ID_oo7p(Urrs70E!9e*ssZ)C<h*H!caB%(Ve1-H+b11YY0jJyts%JS>)rX7eQw%=yqD69+BxXn;@IJahJ(D*ON?&>=-O_K!D) z6nv>$cu|Jje>>j~q-eI>8#l1toWQg^xjo}3aO+!z%uIDe)U!qXyNvzXJPZfBD7iou z2NaQyW7T#I?FyPY{JN?fcWWbm7DnEcW*qbG^N!+HSx=bJfW=3f=0nDOO~0PhVH-M4 zKjcFTgUSiH4IE)AH%&U2{I!O}-C-_2__vz6kI(0Gx|O;P=4Aw{MVj95S#BzPViApO zJkWjVTNShZiq!togQcW*4Mm5MRk#?9<1dB}^5_CcMY?I+u0QWi^(W>nN=8#}I!=6x zhv|dAB|0Lz(hO}OoN2b&0u@cmI6Zf64%CgAnZri9dt(ixkPa2i>wZhmpFQ#WURSTY z|4?{Ai#^U($N+A&Fg#H84^7e z*4J8pW(2(YI(8Ec3-pPN`+7_Yy`-PNP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ILgS(1ENoS Q=X*T>qOPx2sbUlQUv6i{J^%m! literal 0 HcmV?d00001 diff --git a/cog_64.png b/cog_64.png new file mode 100644 index 0000000000000000000000000000000000000000..4f2ad2b2f4fce3c9844a8d08bb35c8fdf1c1e7ef GIT binary patch literal 12269 zcmeHtXIPWlwr)a^rik=zXi@{AL+DMK^eRdTN$5RvsnV;0fOHV)(gZ;|(mP0R3WyXD zY0`^ug08)m>z;l0x%+wU`L}tVkZ;cUj(3dt&N0WAZzd6%>WVk;sqp~-zzt<3d2RH& z^wkUZ8v1{+wevgxK+f!~Yv`&C^8h)yI9gcSAwjNQPDl{a)7k<6@SH78wRUH2a0tFc zk(tQG-&61Zv=+#1H& z+`w7!3hG~=-*4=(m5-I`+ROef-qWxb=u59T{HDy%YB7XSENV&-Tn3%Bt z*=0t>Jns3Fm~hhpMN5WpA5VfDlCFZf}6Jalc}{h?%;pI~zXc=A&c(oxK=x_`*`TMd85oZ52{ z=#+E95Hjnb^GDNbmmf}R`dLiRcc>iQK5U3?%)?)wH6dHd<_4m|R#Ys#lF3M;{eJlS zT%KlEV|m$@pVyFmcEMn1f4a7x_R1;Tn1?pResSvPi05SDb8E$5dWu=otd~5&VQbQi zS<*`hifgf~lXld@n2=lBgx9;g#hny3f?^I;hFEN0!@Hysagb|{Q%-?5T5sH4ci3hc zVlejA2=Mn$fCxL-GSdFr{|Si(qQsMtC@HKHK+K zy#-<+q&h01iMsp)$#SuxD|Rlu)wN3u-J0ggEYG!VR`L>A4YtZ2YTBX(-!_DhKd`Aw z)EC=X_qZu>I9|1$H}xs>_D)AQQ;c|D;h1{1z&4ddy7lUP3u9^f6Swk;B^A!{%CB>_ zleBLyc7JR)S(uuj=5*>IO-)^;>`nAA1y&i!cKB9}r+6pjE|-OmzNg1+Tu6yqF4voi9~CV4?aXS{tUni? zlf##zI`|%Zn?mpT2@d$e+YY-vXl*NHvc#RM3ZG%1$ikMj+31Vy;iKxb?i0PPd(I{6 ziv1FN<9do5tp~5m?muhlr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=y^vZ7KtyFd=veR9Lo|8XWmNm~N>xWaO@8fRD+LD0PdBANtP_MBO z$0PXbz09P(d31w5b5S`}sSk%y!}xiob%mk3q|P0UWDxrl&uSm%V>ki9?h#*+2nBy< zU}c2n>+|zcMQou5;XWwdL!XpDX9ALw82g};2Htk49xn-3(u?vUPF_heRin8L!FSZNj9f%{IzI z7}%Zum_9j`bq2aOw4aOBd*a<-{95-uNDsJ}OH!Y6bQIXLaz=w4pviqC6yQvu*QU&> zf9+a8M04)@Mm-0Z4nc&tml{WJ+-T_I;J`L#JxS^&8u<-MD;|if(W~5~Xq1(>D2`cJ zKjTH~P{}#_yLPkdBoM4s|KR+Bg(v&b{S_G_IH-`SdKNN)Tin8_2OYHox%=M*0j0nf zX#^&L>G>bu@SlcM^t0QGx>N%t7L7uNd4N`O6`6~6tOarM*V3N7V}1A-sQKlSU@}YV zDl{`Lr3%-KWDfu(N8GcIQY;H4kG}+rqI>1`qYs>^or*Th;)tg z-o9=3xEKb|EbUb8-hPdTU!Ftv_}fYQ12x|$MJXbHQOXy(x$y>0jO=OhZO#H&M9%XJ z*PLp?vV}JJ7WU60l;P^L`OO+yGf92|WxNsay|SD{Cd^Kq7c_!=7yMlEQUNiEn-p6t zNeyqt3sE!x{xBo?GInqBY&D<<+#jqShTk=2jhsKqS~G3e88c0hpi4yw=;ubtJRr{C zlD{-}z+ug>0+)#EwabL6Jn8BXUwupQE_WD*TXrN2ry?%I(~%eBCH(7y`{768A51W6 zm-kYX;~O=ou&Q+rTSs6our^OqQq-T#aM z&|AJR;1d0gtP(+6hkA0CBNpT%aP%iK3chhe(yqa~m2} zQD*1eEf4o;rW@!=pAD>=+T@rOzoaD00?qrX9|b6kAklMneUw=pSCgMVc3L>NRaY0~as((Lad3 U6MKOE0096fE2ztt$(lX>FSWT-xc~qF literal 0 HcmV?d00001 diff --git a/config.h.in b/config.h.in index c941a68..fd1546e 100644 --- a/config.h.in +++ b/config.h.in @@ -18,3 +18,4 @@ #pragma once #define APP_NAME "@APP_NAME@" +#define REMARKABLE_BASE_PATH "@DEF_DELE_PREFIX@" diff --git a/main.cpp b/main.cpp index f154339..beb89cc 100644 --- a/main.cpp +++ b/main.cpp @@ -52,10 +52,5 @@ int main (int argc, char* argv[]) { duck::MainWindow win(&roots.back()); win.show(); - for (const duck::NotebookInfo* nb : dele_list) { - for (const auto& f : nb->files) { - std::cout << "/home/root/.local/share/remarkable/xochitl/" << f << '\n'; - } - } return app.exec(); } diff --git a/main_window.cpp b/main_window.cpp index 7d7a3fe..924a4e0 100644 --- a/main_window.cpp +++ b/main_window.cpp @@ -17,19 +17,56 @@ #include "main_window.hpp" #include "notebook_tree_model.hpp" +#include "notebook_tree.hpp" #include "config.h" #include +#include +#include +#include +#include +#include +#include +#include namespace duck { MainWindow::MainWindow (Node* tree) : - m_tree(new QTreeView) + m_tree(new QTreeView), + m_tree_model(new NotebookTreeModel(tree, m_tree)), + m_file_menu(menuBar()->addMenu("&File")), + m_gen_dele_list(new QAction(QPixmap("cog_64.png"), "Generate list", this)), + m_quit_action(new QAction(QPixmap("close_64.png"), "Quit", this)), + m_central_layout(new QHBoxLayout), + m_output(new QTextEdit) { setWindowTitle(APP_NAME); - setCentralWidget(m_tree); - auto* model = new NotebookTreeModel(tree, m_tree); - m_tree->setModel(model); + QWidget* const main_widget = new QWidget; + setCentralWidget(main_widget); + + main_widget->setLayout(m_central_layout); + m_central_layout->addWidget(m_tree); + m_central_layout->addWidget(m_output); + + m_tree->setModel(m_tree_model); + + m_file_menu->addAction(m_gen_dele_list); + connect(m_gen_dele_list, &QAction::triggered, this, &MainWindow::generate_dele_list); + m_quit_action->setShortcuts(QKeySequence::Quit); + m_file_menu->addAction(m_quit_action); + connect(m_quit_action, &QAction::triggered, this, &QApplication::quit); } MainWindow::~MainWindow() noexcept = default; + +void MainWindow::generate_dele_list() { + std::vector list(make_list_of_deleted(m_tree_model->root_node())); + QString out_text; + + for (const auto& nb : list) { + for (const auto& f : nb->files) { + out_text += QString(REMARKABLE_BASE_PATH) + QString::fromStdString(f) + "/n"; + } + } + m_output->setText(out_text); +} } //namespace duck diff --git a/main_window.hpp b/main_window.hpp index 26fbb0e..1f181d4 100644 --- a/main_window.hpp +++ b/main_window.hpp @@ -20,9 +20,14 @@ #include class QTreeView; +class QMenu; +class QAction; +class QHBoxLayout; +class QTextEdit; namespace duck { class Node; +class NotebookTreeModel; class MainWindow : public QMainWindow { Q_OBJECT @@ -30,7 +35,17 @@ public: MainWindow (Node* tree); virtual ~MainWindow() noexcept; +private slots: + void generate_dele_list(); + private: QTreeView* m_tree; + NotebookTreeModel* m_tree_model; + + QMenu* m_file_menu; + QAction* m_gen_dele_list; + QAction* m_quit_action; + QHBoxLayout* m_central_layout; + QTextEdit* m_output; }; } //namespace duck diff --git a/meson.build b/meson.build index dbbe024..61dc547 100644 --- a/meson.build +++ b/meson.build @@ -10,6 +10,7 @@ project('remarkable_tool', 'cpp', conf = configuration_data() conf.set('APP_NAME', meson.project_name()) +conf.set('DEF_DELE_PREFIX', '/home/root/.local/share/remarkable/xochitl/') project_config_file = configure_file( input: 'config.h.in', output: 'config.h', diff --git a/notebook_tree.cpp b/notebook_tree.cpp index f24be28..bce9a39 100644 --- a/notebook_tree.cpp +++ b/notebook_tree.cpp @@ -187,4 +187,8 @@ std::vector make_list_of_deleted (const std::vector& } return dele_list; } + +std::vector make_list_of_deleted (const Node* root) { + return make_dele_list(*root); +} } //namespace duck diff --git a/notebook_tree.hpp b/notebook_tree.hpp index 31b3893..eb5d876 100644 --- a/notebook_tree.hpp +++ b/notebook_tree.hpp @@ -73,4 +73,5 @@ private: }; std::vector make_list_of_deleted (const std::vector& roots); +std::vector make_list_of_deleted (const Node* root); } //namespace duck diff --git a/notebook_tree_model.hpp b/notebook_tree_model.hpp index 851a6a3..000571d 100644 --- a/notebook_tree_model.hpp +++ b/notebook_tree_model.hpp @@ -36,6 +36,9 @@ public: QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const override; QModelIndex parent (const QModelIndex& index) const override; + Node* root_node() { return m_tree; } + const Node* root_node() const { return m_tree; } + private: Node* m_tree; };