Comments (4)
It might be a good idea to make this configurable in case it incurs a performance penalty on large folders, but it probably shouldn't if it's using an epoll-like implementation.
from qimgv.
From 1f249ce5f97b49b81bc7178a42ecf99e7756752d Mon Sep 17 00:00:00 2001
From: Ashkan Kiani <ashkan@zephyr>
Date: Sat, 16 Mar 2019 16:09:43 -0700
Subject: [PATCH] Add directory watching back in.
---
components/directorymanager/directorymanager.cpp | 6 +++---
gui/customwidgets/thumbnailview.cpp | 1 +
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/components/directorymanager/directorymanager.cpp b/components/directorymanager/directorymanager.cpp
index 1448f18..e29f673 100644
--- a/components/directorymanager/directorymanager.cpp
+++ b/components/directorymanager/directorymanager.cpp
@@ -51,9 +51,9 @@ void DirectoryManager::readSettings() {
void DirectoryManager::setDirectory(QString path) {
DirectoryWatcher* watcher = DirectoryWatcher::newInstance();
- //watcher->setFileFilters(extensionFilters);
- //watcher->setWatchPath(path);
- //watcher->observe();
+ watcher->setFileFilters(settings->supportedFormats());
+ watcher->setWatchPath(path);
+ watcher->observe();
connect(watcher, &DirectoryWatcher::observingStarted, this, [] () {
qDebug() << "observing started";
});
diff --git a/gui/customwidgets/thumbnailview.cpp b/gui/customwidgets/thumbnailview.cpp
index 0af9a10..3a67e69 100644
--- a/gui/customwidgets/thumbnailview.cpp
+++ b/gui/customwidgets/thumbnailview.cpp
@@ -88,6 +88,7 @@ void ThumbnailView::addItem() {
// !! calls loadVisibleThumbnails() at the end
void ThumbnailView::insertItem(int index) {
ThumbnailWidget *widget = createThumbnailWidget();
+ widget->setThumbnailSize(mThumbnailSize);
thumbnails.insert(index, widget);
addItemToLayout(widget, index);
fitSceneToContents();
--
2.21.0
@easymodo I looked through the code and noticed that the functionality was essentially already there. I did notice that the thumbnail was a bit broken in the gallery view, but it turns out it was missing a call to properly set the size. I've been using it since I fixed it, so I'm wondering what was missing from adding it? It seems to work just fine.
from qimgv.
build the dev branch it's already hooked up there
what was missing from adding it?
Yeah it was mostly there but pretty buggy iirc
from qimgv.
@easymodo ah I didn't see that since I did a shallow update. Thanks!
from qimgv.
Related Issues (20)
- Network shares won't render images
- Image has wrong scale with multiple monitors in different scale HOT 2
- Update Qt to 6.6 HOT 1
- Time to switch HOT 9
- The application crashes when trying to view some JXL files HOT 1
- App crashes on ICO (v1.0.3-alpha-101) HOT 1
- Some SVG images, aren't displayed at all
- [Feature] German translation HOT 1
- [FEATURE] manual labels on the "move to" quick folders.
- How do I designate a quick folder? HOT 2
- [Feature request] Automatically switch to nearest neighbour upscaling for very small pictures (Pixelart)
- Failed to build with exiv2 v0.28.0 HOT 1
- Dark fusion theme [Qt6, Win11] HOT 4
- advices
- Zoom out less than 100% HOT 2
- Some keystroke detection is broken [Qt 6.7.0] HOT 4
- Feature: Add option to use embedded cover as thumbnail (for video files)
- Video playback detaches on mpv v0.38.0 HOT 3
- I can't delete gif file in it
- NEED IMPROVEMENTS FOR WINDOWS 11!
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from qimgv.