some work on the grid layout and items
This commit is contained in:
20
src/View/GridItemView/GridItemView.cpp
Normal file
20
src/View/GridItemView/GridItemView.cpp
Normal file
@@ -0,0 +1,20 @@
|
||||
#include "GridItemView.hpp"
|
||||
#include <iostream>
|
||||
|
||||
GridItemView::GridItemView(QWidget* parent)
|
||||
: QFrame(parent),
|
||||
fileController(std::make_shared<FileController>( )) {
|
||||
|
||||
QGridLayout* mainLayout = new QGridLayout( );
|
||||
|
||||
connect(fileController.get( ), &FileController::newPathEntered, this, [this, mainLayout](const std::unordered_map<std::filesystem::path, std::filesystem::file_time_type> paths) {
|
||||
std::cout << "path.first" << std::endl;
|
||||
|
||||
for (auto path : paths) {
|
||||
mainLayout->addWidget(new GridItem(path.first, this));
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
GridItemView::~GridItemView( ) { }
|
||||
Reference in New Issue
Block a user