Add mode switching.

This commit is contained in:
2020-05-23 13:55:16 +02:00
parent 2907cf6574
commit 87bfce1a46
6 changed files with 75 additions and 39 deletions

View File

@@ -1,6 +1,6 @@
import os, sets, random, httpClient, json, strformat, options
import gintro/[gdkpixbuf, gobject]
import commands
import common
const
supportedExts = @[".png", ".jpg", ".jpeg"]
@@ -12,12 +12,6 @@ type
FileOpResult* = object of OpResult
file*: string
Mode* {.pure.} = enum ## Options for the display mode
None = "none" ## No images will be displayed
Foxes = "foxes" ## Some nice foxes
Inspiro = "inspiro" ## Inspiring nonsense
File = "file" ## Images from a local path
ImageProvider* = ref object of RootObj
## Manages images that should be displayed
verbose: bool ## Additional logging for the image provider