diff --git a/src/debs/gwinwrap-0-0-2-x64/DEBIAN/control b/src/debs/gwinwrap-0-0-2-x64/DEBIAN/control new file mode 100644 index 0000000..ecb249e --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/DEBIAN/control @@ -0,0 +1,8 @@ +Package: gwinwrap64 +Version: 0.0-2 +Section: python +Priority: optional +Architecture: amd64 +Depends: ffmpegthumbnailer (>= 2.0.10-0.1), mplayer (>=2.0-728-g2c378c7-4), gifsicle (>=1.86-1), nitrogen (>=1.5.2-2), xscreensaver (>=5.36-1ubuntu1), xscreensaver-gl (>=5.36-1ubuntu1), xscreensaver-gl-extra (>=5.36-1ubuntu1), xscreensaver-screensaver-dizzy (>=0.3-3), xscreensaver-screensaver-bsod (>=5.36-1ubuntu1), xscreensaver-data (>=5.36-1ubuntu1), xscreensaver-data-extra (>=5.36-1ubuntu1), xscreensaver-screensaver-webcollage (>=5.36-1ubuntu1) +Maintainer: Maxim Stewart <1itdominator@gmail.com> +Description: GWinWrap is a GUI to handle setting XWinWrap options. diff --git a/src/debs/gwinwrap-0-0-2-x64/DEBIAN/postrm b/src/debs/gwinwrap-0-0-2-x64/DEBIAN/postrm new file mode 100755 index 0000000..5a54f11 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/DEBIAN/postrm @@ -0,0 +1,15 @@ +#!/bin/bash +#postrm (script executed after uninstalling the package) +#set -e + +if [ -f /bin/xwinwrap ]; then + rm /bin/xwinwrap +fi + +if [ -d /opt/GWinWrap ]; then + rm -rf /opt/GWinWrap +fi + +if [ -d /usr/share/gwinwrap ]; then + rm -rf /usr/share/gwinwrap +fi diff --git a/src/debs/gwinwrap-0-0-2-x64/bin/gwinwrap b/src/debs/gwinwrap-0-0-2-x64/bin/gwinwrap new file mode 100755 index 0000000..2166a10 Binary files /dev/null and b/src/debs/gwinwrap-0-0-2-x64/bin/gwinwrap differ diff --git a/src/debs/gwinwrap-0-0-2-x64/bin/xwinwrap b/src/debs/gwinwrap-0-0-2-x64/bin/xwinwrap new file mode 100755 index 0000000..26eafd7 Binary files /dev/null and b/src/debs/gwinwrap-0-0-2-x64/bin/xwinwrap differ diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__builtins__.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__builtins__.py new file mode 100644 index 0000000..287a5fb --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__builtins__.py @@ -0,0 +1,73 @@ +import builtins + +# Python imports +import builtins + +# Lib imports + +# Application imports +from signal_classes import IPCServerMixin + + + +class Builtins(IPCServerMixin): + """Docstring for __builtins__ extender""" + + def __init__(self): + # NOTE: The format used is list of [type, target, data] + # Where data may be any kind of data + self._gui_events = [] + self._fm_events = [] + self.is_ipc_alive = False + self.ipc_authkey = b'GWinWrap-ipc' + self.ipc_address = '127.0.0.1' + self.ipc_port = 8888 + self.ipc_timeout = 15.0 + + # Makeshift fake "events" type system FIFO + def _pop_gui_event(self): + if len(self._gui_events) > 0: + return self._gui_events.pop(0) + return None + + def _pop_fm_event(self): + if len(self._fm_events) > 0: + return self._fm_events.pop(0) + return None + + + def push_gui_event(self, event): + if len(event) == 3: + self._gui_events.append(event) + return None + + raise Exception("Invald event format! Please do: [type, target, data]") + + def push_fm_event(self, event): + if len(event) == 3: + self._fm_events.append(event) + return None + + raise Exception("Invald event format! Please do: [type, target, data]") + + def read_gui_event(self): + return self._gui_events[0] + + def read_fm_event(self): + return self._fm_events[0] + + def consume_gui_event(self): + return self._pop_gui_event() + + def consume_fm_event(self): + return self._pop_fm_event() + + + +# NOTE: Just reminding myself we can add to builtins two different ways... +# __builtins__.update({"event_system": Builtins()}) +builtins.app_name = "GWinWrap" +builtins.event_system = Builtins() +builtins.event_sleep_time = 0.2 +builtins.debug = False +builtins.trace_debug = False diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__init__.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__init__.py new file mode 100644 index 0000000..56356ba --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__init__.py @@ -0,0 +1,50 @@ +# Python imports +import os, inspect, time + +# Lib imports + +# Application imports +from utils import Settings +from signal_classes import Controller +from __builtins__ import Builtins + + + + +class Main(Builtins): + def __init__(self, args, unknownargs): + if not debug: + event_system.create_ipc_server() + + time.sleep(0.2) + if not trace_debug: + if not event_system.is_ipc_alive: + if unknownargs: + for arg in unknownargs: + if os.path.isdir(arg): + message = f"FILE|{arg}" + event_system.send_ipc_message(message) + + raise Exception("IPC Server Exists: Will send data to it and close...") + + + settings = Settings() + settings.create_window() + + controller = Controller(settings, args, unknownargs) + if not controller: + raise Exception("Controller exited and doesn't exist...") + + # Gets the methods from the classes and sets to handler. + # Then, builder from settings will connect to any signals it needs. + classes = [controller] + handlers = {} + for c in classes: + methods = None + try: + methods = inspect.getmembers(c, predicate=inspect.ismethod) + handlers.update(methods) + except Exception as e: + print(repr(e)) + + settings.get_builder().connect_signals(handlers) diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__main__.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__main__.py new file mode 100644 index 0000000..dc06b1a --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/__main__.py @@ -0,0 +1,39 @@ +#!/usr/bin/python3 + + +# Python imports +import argparse, faulthandler, traceback +from setproctitle import setproctitle + +import tracemalloc +tracemalloc.start() + + +# Lib imports +import gi +gi.require_version('Gtk', '3.0') +from gi.repository import Gtk + +# Application imports +from __init__ import Main + + +if __name__ == "__main__": + try: + # import web_pdb + # web_pdb.set_trace() + + setproctitle('GWinWrap') + faulthandler.enable() # For better debug info + parser = argparse.ArgumentParser() + # Add long and short arguments + parser.add_argument("--file", "-f", default="default", help="JUST SOME FILE ARG.") + + # Read arguments (If any...) + args, unknownargs = parser.parse_known_args() + + Main(args, unknownargs) + Gtk.main() + except Exception as e: + traceback.print_exc() + quit() diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/gwinwrap b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/gwinwrap new file mode 100755 index 0000000..2166a10 Binary files /dev/null and b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/gwinwrap differ diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/Controller.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/Controller.py new file mode 100644 index 0000000..adcb743 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/Controller.py @@ -0,0 +1,151 @@ +# Python imports +import threading, signal, subprocess, inspect, os, time + +# Gtk imports +import gi +gi.require_version('Gtk', '3.0') +gi.require_version('Gdk', '3.0') +from gi.repository import Gtk, GLib, Gdk + +# Application imports +from .mixins import * +from . import Controller_Data + + +def threaded(fn): + def wrapper(*args, **kwargs): + threading.Thread(target=fn, args=args, kwargs=kwargs).start() + + return wrapper + + +class Controller(ThumbnailMixin, ImageViewerMixin, DrawAreaMixin, GridMixin, Controller_Data): + def __init__(self, _settings, args, unknownargs): + self.setup_controller_data(_settings) + self.window.show() + self.retrieve_settings() + + + def tear_down(self, widget=None, eve=None): + event_system.send_ipc_message("close server") + if self.demo_area_pid: + self.close_demo_popup() + + self.close_image_popup() + time.sleep(event_sleep_time) + Gtk.main_quit() + + def close_program(self, widget, data=None): + self.tear_down() + + + @threaded + def gui_event_observer(self): + while True: + time.sleep(event_sleep_time) + event = event_system.consume_gui_event() + if event: + try: + type, target, data = event + method = getattr(self.__class__, type) + GLib.idle_add(method, (self, data,)) + except Exception as e: + print(repr(e)) + + + + def apply_settings(self, widget, data=None): + os.system("killall xwinwrap &") + user_home = self.settings.get_home_path() + + if self.apply_type == 1: + files = os.listdir(user_home) + for file in files: + fPath = f"{user_home}/{file}" + if os.path.isfile(fPath) and "animatedBGstarter" in file: + os.system(f"bash -c '~/{file}' &") + elif self.apply_type == 2: + os.system("nitrogen --restore &") + else: + os.system("nitrogen --restore &") + + self.help_label.set_markup(self.appliedLabel) + + def save_to_settings_file(self, widget): + self.start_path = self.builder.get_object("customStartPath").get_text().strip() + self.default_player = self.builder.get_object("customVideoPlayer").get_text().strip() + self.default_img_viewer = self.builder.get_object("customImgViewer").get_text().strip() + + self.settings_saver.save_settings(self.start_path, self.default_player, self.default_img_viewer) + + def save_to_file(self, widget, data=None): + save_location = self.builder.get_object("saveLoc").get_active_text() + use_xscreensvr = self.builder.get_object("useXScrnList").get_active() + playBackRes = self.builder.get_object("playbackResolution") + monitorOffset = self.builder.get_object("monitorOffsetData") + resolution = playBackRes.get_active_text() + monitorOffset.get_active_text() + self.apply_type = self.state_saver.save_to_file(self.to_be_background, resolution, save_location, use_xscreensvr, self.xscreen_value, self.default_player) + + if self.apply_type == -1: + self.help_label.set_markup("Nothing saved...") + return + + self.help_label.set_markup(self.savedLabel) + + + def toggle_xscreen_list(self, widget, data=None): + use_xscreensvr = self.builder.get_object("useXScrnList") + if use_xscreensvr.get_active(): + self.builder.get_object("xScreenSvrList").set_sensitive(True) + else: + self.builder.get_object("xScreenSvrList").set_sensitive(False) + + def show_settings_popup(self, widget): + self.builder.get_object("settingsWindow").popup() + + + def preview_xscreensaver(self, widget, eve): + if eve.type == Gdk.EventType.DOUBLE_BUTTON_PRESS: + demoXscrnSaver = self.xscreensavers + self.xscreen_value + xid = self.getXID() + command = [demoXscrnSaver, "-window-id", str(xid)] + self.run_demo_in_draw_area(command) + + def pass_xscreen_value(self, widget): + row = widget.get_cursor() + path = Gtk.TreePath(row.path) + treeiter = self.xscreen_store.get_iter(path[0]) + self.xscreen_value = self.xscreen_store.get_value(treeiter, 0) + + def kill_xwinwrap(self, widget, data=None): + os.system("killall xwinwrap &") + self.help_label.set_markup(self.stoppedLabel) + + def set_selected_eve_box(self, eveBox): + if self.selected_eve_box: + color = Gdk.RGBA(0.0, 0.0, 0.0, 0.0) + self.selected_eve_box.override_background_color(Gtk.StateType.NORMAL, color) + + color = Gdk.RGBA(0.9, 0.7, 0.4, 0.74) + eveBox.override_background_color(Gtk.StateType.NORMAL, color) + self.selected_eve_box = eveBox + + def mouse_over(self, widget, eve, args): + hand_cursor = Gdk.Cursor(Gdk.CursorType.HAND2) + self.window.get_window().set_cursor(hand_cursor) + + def mouse_out(self, widget, eve, args): + watch_cursor = Gdk.Cursor(Gdk.CursorType.LEFT_PTR) + self.window.get_window().set_cursor(watch_cursor) + + def get_clipboard_data(self): + proc = subprocess.Popen(['xclip','-selection', 'clipboard', '-o'], stdout=subprocess.PIPE) + retcode = proc.wait() + data = proc.stdout.read() + return data.decode("utf-8").strip() + + def set_clipboard_data(self, data): + proc = subprocess.Popen(['xclip','-selection','clipboard'], stdin=subprocess.PIPE) + proc.stdin.write(data) + proc.stdin.close() + retcode = proc.wait() diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/Controller_Data.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/Controller_Data.py new file mode 100644 index 0000000..e651a46 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/Controller_Data.py @@ -0,0 +1,102 @@ +# Python imports +import signal +from os import listdir +from os.path import isfile, join + +# Lib imports +from gi.repository import GLib + +# Application imports +from . import SaveStateToXWinWarp, SaveGWinWrapSettings + + + +class Controller_Data: + def has_method(self, obj, name): + return callable(getattr(obj, name, None)) + + def setup_controller_data(self, _settings): + self.settings = _settings + self.state_saver = SaveStateToXWinWarp(_settings) + self.settings_saver = SaveGWinWrapSettings(_settings) + + + self.builder = self.settings.get_builder() + self.window = self.settings.get_main_window() + self.logger = self.settings.get_logger() + + self.home_path = self.settings.get_home_path() + self.success_color = self.settings.get_success_color() + self.warning_color = self.settings.get_warning_color() + self.error_color = self.settings.get_error_color() + + + self.image_grid = self.builder.get_object("imageGrid") + self.grid_label = self.builder.get_object("gridLabel") + self.help_label = self.builder.get_object("helpLabel") + self.xscreen_store = self.builder.get_object("XScreensaverStore") + + self.defaultLabel = "Note: Double click an image to view the video or image." + self.savedLabel = f"Saved settings..." + self.appliedLabel = f"Running xwinwrap..." + self.stoppedLabel = f"Stopped xwinwrap..." + + # Add filter to allow only folders to be selected + dialog = self.builder.get_object("selectedDirDialog") + file_filter = self.builder.get_object("Folders") + dialog.add_filter(file_filter) + + self.xscreensavers = self.settings.get_xscreensavers() + list = [f for f in listdir(self.xscreensavers) if isfile(join(self.xscreensavers , f))] + list.sort() + for file in list: + self.xscreen_store.append((file,)) + + + self.selected_eve_box = None + self.start_path = None + self.default_player = None + self.default_img_viewer = None + self.demo_area_pid = None + + self.apply_type = 1 # 1 is XWinWrap and 2 is Nitrogen + self.xscreen_value = None + self.to_be_background = None # Global file path and type for saving to file + + + self.window.connect("delete-event", self.tear_down) + GLib.unix_signal_add(GLib.PRIORITY_DEFAULT, signal.SIGINT, self.tear_down) + + self.set_monitor_offset_data() + self.retrieve_settings() + + + def set_monitor_offset_data(self): + monitors = self.settings.get_monitor_data() + monitorOffsetData = self.builder.get_object("monitorOffsetData") + + for monitor in monitors: + if monitor.x >= 0 and monitor.y >= 0: + monitorOffsetData.append_text("+" + str(monitor.x) + "+" + str(monitor.y)) + elif monitor.x <= 0 and monitor.y <= 0: + monitorOffsetData.append_text(str(monitor.x) + str(monitor.y)) + elif monitor.x >= 0 and monitor.y <= 0: + monitorOffsetData.append_text("+" + str(monitor.x) + str(monitor.y)) + elif monitor.x <= 0 and monitor.y >= 0: + monitorOffsetData.append_text(str(monitor.x) + "+" + str(monitor.y)) + + monitorOffsetData.set_active(0) + + def retrieve_settings(self): + data = self.settings_saver.retrieve_settings() + self.start_path = data[0] + self.default_player = data[1] + self.default_img_viewer = data[2] + + self.builder.get_object("customStartPath").set_text(self.start_path) + self.builder.get_object("customVideoPlayer").set_text(self.default_player) + self.builder.get_object("customImgViewer").set_text(self.default_img_viewer) + self.builder.get_object("selectedDirDialog").set_filename(self.start_path) + + if self.start_path: + self.load_path(None, self.start_path) diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/IPCServerMixin.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/IPCServerMixin.py new file mode 100644 index 0000000..be92ace --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/IPCServerMixin.py @@ -0,0 +1,64 @@ +# Python imports +import threading, socket, time +from multiprocessing.connection import Listener, Client + +# Lib imports + +# Application imports + + +def threaded(fn): + def wrapper(*args, **kwargs): + threading.Thread(target=fn, args=args, kwargs=kwargs, daemon=True).start() + return wrapper + + + + +class IPCServerMixin: + + @threaded + def create_ipc_server(self): + listener = Listener((self.ipc_address, self.ipc_port), authkey=self.ipc_authkey) + self.is_ipc_alive = True + while True: + conn = listener.accept() + start_time = time.time() + + print(f"New Connection: {listener.last_accepted}") + while True: + msg = conn.recv() + if debug: + print(msg) + + if "FILE|" in msg: + file = msg.split("FILE|")[1].strip() + if file: + event_system.push_gui_event(["create_tab_from_ipc", None, file]) + + conn.close() + break + + + if msg == 'close connection': + conn.close() + break + if msg == 'close server': + conn.close() + break + + # NOTE: Not perfect but insures we don't lockup the connection for too long. + end_time = time.time() + if (end - start) > self.ipc_timeout: + conn.close() + + listener.close() + + + def send_ipc_message(self, message="Empty Data..."): + try: + conn = Client((self.ipc_address, self.ipc_port), authkey=self.ipc_authkey) + conn.send(message) + conn.send('close connection') + except Exception as e: + print(repr(e)) diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/SaveGWinWrapSettings.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/SaveGWinWrapSettings.py new file mode 100644 index 0000000..38025a1 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/SaveGWinWrapSettings.py @@ -0,0 +1,49 @@ +#!/usr/bin/env python + +import os, json + +class SaveGWinWrapSettings: + def __init__(self, settings): + self.config_file = settings.get_config_file() + + if os.path.isfile(self.config_file) == False: + open(self.config_file, 'a').close() + + + def save_settings(self, start_path, default_player, default_img_viewer): + data = {} + data['settings'] = [] + + data['settings'].append({ + 'start_path': start_path, + 'default_player': default_player, + 'default_img_viewer': default_img_viewer + }) + + with open(self.config_file, 'w') as outfile: + json.dump(data, outfile, separators=(',', ':'), indent=4) + + + def retrieve_settings(self): + data = [] + + with open(self.config_file) as infile: + try: + _data = json.load(infile) + for obj in _data['settings']: + data = [obj['start_path'], obj['default_player'], obj['default_img_viewer']] + except Exception as e: + print(repr(e)) + data = ['', 'mplayer', 'xdg-open'] + + + if data[0] == '': + data[0] = '' + + if data[1] == '': + data[1] = 'mplayer' + + if data[2] == '': + data[2] = 'xdg-open' + + return data diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/SaveStateToXWinWarp.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/SaveStateToXWinWarp.py new file mode 100644 index 0000000..14ff763 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/SaveStateToXWinWarp.py @@ -0,0 +1,68 @@ + +class SaveStateToXWinWarp: + def __init__(self, _settings): + self.settings = _settings + self.user_home = self.settings.get_home_path() + + self._file_writer = None + self._to_be_background = None + self._use_xscreensvr = None + self._xscreen_value = None + self._save_file_target = None + self._resolution = None + self._player = None + + + def save_to_file(self, to_be_background, resolution, save_location, + use_xscreensvr, xscreen_value, player): + + self._to_be_background = to_be_background + self._use_xscreensvr = use_xscreensvr + self._xscreen_value = xscreen_value + self._resolution = resolution + self._player = player + + # Saves to file with selected and needed settings + if to_be_background: + if to_be_background.lower().endswith(self.settings.get_images_filter()): + self._save_file_target = f"{self.user_home}/.config/nitrogen/bg-saved.cfg" + else: + self._save_file_target = f"{self.user_home}/{save_location}" + elif use_xscreensvr and xscreen_value: + self._save_file_target = f"{self.user_home}/{save_location}" + else: + return -1 + + if self._save_file_target: + self._file_writer = open(self._save_file_target, "w") + + return self.save() + + def save(self): + applyType = 1 + output = None + + # XSCREENSAVER + if self._use_xscreensvr: + output = f"xwinwrap -ov -g {self._resolution} -st -sp -b -nf -s -ni -- /usr/lib/xscreensaver/{self._xscreen_value} -window-id WID -root"; + # GIF + elif self._to_be_background.lower().endswith(('.gif')): + output = f"xwinwrap -ov -g {self._resolution} -st -sp -b -nf -s -ni -- gifview -a -w WID {self._to_be_background}"; + # Standard images using nitrogen + elif self._to_be_background.lower().endswith(('.png', 'jpg', '.jpeg')): + output = f"[xin_0] \nfile={self._to_be_background}\nmode=0 \nbgcolor=#000000\n\n[xin_1] \nfile={self._to_be_background}\nmode=0 \nbgcolor=#000000"; + applyType = 2; + # VIDEO + else: + output = f"xwinwrap -ov -g {self._resolution} -st -sp -b -nf -s -ni -- {self._player} -wid WID -really-quiet -ao null -loop 0 '{self._to_be_background}'"; + pass + + try: + if self._file_writer: + self._file_writer.write(output) + self._file_writer.close() + except Exception as e: + print(":: Write failed! ::") + print(e) + + return applyType; diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/__init__.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/__init__.py new file mode 100644 index 0000000..97a8b3b --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/__init__.py @@ -0,0 +1,9 @@ +""" + Gtk Bound Signal Module +""" +from .mixins import * +from .SaveStateToXWinWarp import SaveStateToXWinWarp +from .SaveGWinWrapSettings import SaveGWinWrapSettings +from .IPCServerMixin import IPCServerMixin +from .Controller_Data import Controller_Data +from .Controller import Controller diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/DrawAreaMixin.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/DrawAreaMixin.py new file mode 100644 index 0000000..833d3ae --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/DrawAreaMixin.py @@ -0,0 +1,59 @@ +# Python imports +import os, subprocess, signal, time + +# Gtk imports +import gi +gi.require_version('Gdk', '3.0') +from gi.repository import Gdk + +# Application imports + + +class DrawAreaMixin: + """docstring for DrawAreaMixin""" + + def close_demo_popup(self, widget=None, data=None): + os.kill(self.demo_area_pid, signal.SIGTERM) #or signal.SIGKILL + self.demo_area_pid = None + time.sleep(.200) + self.builder.get_object("demoPreviewPopWindow").popdown() + + def run_mplayer_process(self, widget, eve, params): + video, file, eveBox = params + self.set_selected_eve_box(eveBox) + + if eve.type == Gdk.EventType.DOUBLE_BUTTON_PRESS: + if self.default_player == "mplayer": + xid = self.getXID() + command = [self.default_player, video, "-slave", "-wid", str(xid), "-really-quiet", "-ao", "null", "-loop", "0"] + self.run_demo_in_draw_area(command) + else: + subprocess.call([self.default_player, video, "-really-quiet", "-ao", "null", "-loop", "0"]) + + + self.to_be_background = video + self.applyType = 1 + self.help_label.set_markup(f"{file}") + + def run_demo_in_draw_area(self, command): + self.help_label.set_markup("") + + if self.demo_area_pid: + os.kill(self.demo_area_pid, signal.SIGTERM) #or signal.SIGKILL + self.demo_area_pid = None + time.sleep(.800) # 800 mili-seconds to ensure first process dead + + process = subprocess.Popen(command) + self.demo_area_pid = process.pid + + def getXID(self): + # Must be actualized before getting window + popup = self.builder.get_object("demoPreviewPopWindow") + + if popup.get_visible() == False: + popup.show_all() + popup.popup() + + preview = self.builder.get_object("demoPreview") + window = preview.get_window() + return window.get_xid() diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/GridMixin.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/GridMixin.py new file mode 100644 index 0000000..513d7b1 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/GridMixin.py @@ -0,0 +1,116 @@ +# Python imports +import threading, hashlib +from os import listdir +from os.path import isfile, join + +# Gtk imports +import gi +gi.require_version('Gtk', '3.0') +from gi.repository import Gtk, GLib + +# Application imports + + + + + +def threaded(fn): + def wrapper(*args, **kwargs): + threading.Thread(target=fn, args=args, kwargs=kwargs).start() + + return wrapper + + +class GridMixin: + """docstring for GridMixin.""" + + def set_new_path(self, widget, data=None): + dir = widget.get_filename() + self.load_path(None, dir) + + def load_path(self, widget=None, dir=''): + path = dir + list = [f for f in listdir(path) if isfile(join(path, f))] + files = [] + row = 0 + col = 0 + + for file in list: + if file.lower().endswith(self.settings.get_vids_filter() + \ + self.settings.get_images_filter()): + files.append(file) + + # fractionTick = 1.0 / 1.0 if len(files) == 0 else len(files) + # tickCount = 0.0 + self.clear() + self.image_grid.remove_column(0) + # self.loadProgress.set_text("Loading...") + # self.loadProgress.set_fraction(0.0) + self.help_label.set_markup(f"{path.strip(self.settings.get_home_path())}") + for file in files: + self.porocess_file(path, file, col, row) + + col += 1 + if col == 2: + col = 0 + row += 1 + + # self.loadProgress.set_text("Finished...") + + @threaded + def porocess_file(self, path, file, col, row): + fPath = f"{path}/{file}" + eveBox = Gtk.EventBox() + thumbnl = Gtk.Image() + + if file.lower().endswith(self.settings.get_vids_filter()): + fileHash = hashlib.sha256(str.encode(fPath)).hexdigest() + hashImgPath = f"{self.settings.get_home_path()}/.thumbnails/normal/{fileHash}.png" + if isfile(hashImgPath) == False: + self.generate_thumbnail(fPath, hashImgPath) + + thumbnl = self.create_gtk_image(hashImgPath, [310, 310]) + eveBox.connect("button_press_event", self.run_mplayer_process, (fPath, file, eveBox,)) + eveBox.connect("enter_notify_event", self.mouse_over, ()) + eveBox.connect("leave_notify_event", self.mouse_out, ()) + elif file.lower().endswith(self.settings.get_images_filter()): + thumbnl = self.create_gtk_image(fPath, [310, 310]) + eveBox.connect("button_press_event", self.run_image_viewer_process, (fPath, file, eveBox,)) + eveBox.connect("enter_notify_event", self.mouse_over, ()) + eveBox.connect("leave_notify_event", self.mouse_out, ()) + else: + print("Not a video or image file.") + return + + GLib.idle_add(self.pre_grid_setup, (eveBox, thumbnl, )) + GLib.idle_add(self.add_to_grid, (self.image_grid, eveBox, col, row,)) + # tickCount = tickCount + fractionTick + # self.loadProgress.set_fraction(tickCount) + + def pre_grid_setup(self, args): + args[0].show() + args[1].show() + args[0].add(args[1]) + + def add_to_grid(self, args): + args[0].attach(args[1], args[2], args[3], 1, 1) + + def clear_selection(self, widget, data=None): + self.clear() + + def clear(self): + while True: + if self.image_grid.get_child_at(0,0)!= None: + self.image_grid.remove_row(0) + else: + break + + self.image_grid.attach(self.grid_label, 0, 0, 1, 1) + self.builder.get_object("xScreenSvrList").set_sensitive(False) + self.builder.get_object("useXScrnList").set_active(False) + self.help_label.set_markup(self.defaultLabel) + # self.loadProgress.set_text("") + # self.loadProgress.set_fraction(0.0) + self.xscreen_value = None + self.to_be_background = None + self.apply_type = 1 diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/ImageViewerMixin.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/ImageViewerMixin.py new file mode 100644 index 0000000..e4dd1b6 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/ImageViewerMixin.py @@ -0,0 +1,34 @@ +# Python imports +import subprocess + +# Gtk imports +import gi +gi.require_version('Gdk', '3.0') +from gi.repository import Gdk + +# Application imports + + +class ImageViewerMixin: + """docstring for ImageViewerMixin""" + + def close_image_popup(self, widget=None): + self.builder.get_object("previewWindow").popdown() + + def open_main_image_viewer(self, widget): + subprocess.call([self.default_img_viewer, self.to_be_background]) + + def run_image_viewer_process(self, widget, eve, params): + image, file, eveBox = params + self.set_selected(eveBox) + + if eve.type == Gdk.EventType.DOUBLE_BUTTON_PRESS: + previewWindow = self.builder.get_object("previewWindow") + previewImg = self.builder.get_object("previewImg") + previewImg.set_from_file(image) + previewWindow.show_all() + previewWindow.popup() + + self.to_be_background = image + self.apply_type = 2 + self.help_label.set_markup(f"{file}") diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/ThumbnailMixin.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/ThumbnailMixin.py new file mode 100644 index 0000000..e067732 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/ThumbnailMixin.py @@ -0,0 +1,56 @@ +# Python imports +import subprocess + +# Gtk imports +import gi +gi.require_version('Gtk', '3.0') +from gi.repository import Gtk +from gi.repository import GdkPixbuf + +# Application imports + + +class ThumbnailMixin: + """docstring for ThumbnailMixin""" + + def create_gtk_image(self, path, wxh): + try: + pixbuf = GdkPixbuf.Pixbuf.new_from_file_at_scale( + filename = path, + width = wxh[0], + height = wxh[1], + preserve_aspect_ratio = True) + return Gtk.Image.new_from_pixbuf(pixbuf) + except Exception as e: + print(repr(e)) + + return Gtk.Image() + + def generate_thumbnail(self, fullPathFile, hashImgpth): + # Stream duration + command = ["ffprobe", "-v", "error", "-select_streams", "v:0", "-show_entries", "stream=duration", "-of", "default=noprint_wrappers=1:nokey=1", fullPathFile] + data = subprocess.run(command, stdout=subprocess.PIPE) + duration = data.stdout.decode('utf-8') + + # Format (container) duration + if "N/A" in duration: + command = ["ffprobe", "-v", "error", "-show_entries", "format=duration", "-of", "default=noprint_wrappers=1:nokey=1", fullPathFile] + data = subprocess.run(command , stdout=subprocess.PIPE) + duration = data.stdout.decode('utf-8') + + # Stream duration type: image2 + if "N/A" in duration: + command = ["ffprobe", "-v", "error", "-select_streams", "v:0", "-f", "image2", "-show_entries", "stream=duration", "-of", "default=noprint_wrappers=1:nokey=1", fullPathFile] + data = subprocess.run(command, stdout=subprocess.PIPE) + duration = data.stdout.decode('utf-8') + + # Format (container) duration type: image2 + if "N/A" in duration: + command = ["ffprobe", "-v", "error", "-f", "image2", "-show_entries", "format=duration", "-of", "default=noprint_wrappers=1:nokey=1", fullPathFile] + data = subprocess.run(command , stdout=subprocess.PIPE) + duration = data.stdout.decode('utf-8') + + # Get frame roughly 35% through video + grabTime = str( int( float( duration.split(".")[0] ) * 0.35) ) + command = ["ffmpeg", "-ss", grabTime, "-i", fullPathFile, "-an", "-vframes", "1", "-s", "320x180", "-q:v", "2", hashImgpth] + subprocess.call(command) diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/__init__.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/__init__.py new file mode 100644 index 0000000..f482286 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/signal_classes/mixins/__init__.py @@ -0,0 +1,4 @@ +from .ThumbnailMixin import ThumbnailMixin +from .DrawAreaMixin import DrawAreaMixin +from .ImageViewerMixin import ImageViewerMixin +from .GridMixin import GridMixin diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/Logger.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/Logger.py new file mode 100644 index 0000000..c7f294e --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/Logger.py @@ -0,0 +1,56 @@ +# Python imports +import os, logging + +# Application imports + + +class Logger: + def __init__(self): + pass + + def get_logger(self, loggerName = "NO_LOGGER_NAME_PASSED", createFile = True): + """ + Create a new logging object and return it. + :note: + NOSET # Don't know the actual log level of this... (defaulting or literally none?) + Log Levels (From least to most) + Type Value + CRITICAL 50 + ERROR 40 + WARNING 30 + INFO 20 + DEBUG 10 + :param loggerName: Sets the name of the logger object. (Used in log lines) + :param createFile: Whether we create a log file or just pump to terminal + + :return: the logging object we created + """ + + globalLogLvl = logging.DEBUG # Keep this at highest so that handlers can filter to their desired levels + chLogLevel = logging.CRITICAL # Prety musch the only one we change ever + fhLogLevel = logging.DEBUG + log = logging.getLogger(loggerName) + log.setLevel(globalLogLvl) + + # Set our log output styles + fFormatter = logging.Formatter('[%(asctime)s] %(pathname)s:%(lineno)d %(levelname)s - %(message)s', '%m-%d %H:%M:%S') + cFormatter = logging.Formatter('%(pathname)s:%(lineno)d] %(levelname)s - %(message)s') + + ch = logging.StreamHandler() + ch.setLevel(level=chLogLevel) + ch.setFormatter(cFormatter) + log.addHandler(ch) + + if createFile: + folder = "logs" + file = folder + "/application.log" + + if not os.path.exists(folder): + os.mkdir(folder) + + fh = logging.FileHandler(file) + fh.setLevel(level=fhLogLevel) + fh.setFormatter(fFormatter) + log.addHandler(fh) + + return log diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/Settings.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/Settings.py new file mode 100644 index 0000000..e729ee4 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/Settings.py @@ -0,0 +1,112 @@ +# Python imports +import os + +# Gtk imports +import gi, cairo +gi.require_version('Gtk', '3.0') +gi.require_version('Gdk', '3.0') + +from gi.repository import Gtk +from gi.repository import Gdk + + +# Application imports +from . import Logger + + + +class Settings: + def __init__(self): + self._SCRIPT_PTH = os.path.dirname(os.path.realpath(__file__)) + self._USER_HOME = os.path.expanduser('~') + self._CONFIG_PATH = f"{self._USER_HOME}/.config/{app_name.lower()}" + self._GLADE_FILE = f"{self._CONFIG_PATH}/Main_Window.glade" + self._CSS_FILE = f"{self._CONFIG_PATH}/stylesheet.css" + self._DEFAULT_ICONS = f"{self._CONFIG_PATH}/icons" + self._WINDOW_ICON = f"{self._DEFAULT_ICONS}/{app_name.lower()}.png" + self._USR_PATH = f"/usr/share/{app_name.lower()}" + self._CONFIG_FILE = f"{self._CONFIG_PATH}/settings.json" + self._XSCREEN_SAVERS = "/usr/lib/xscreensaver/" + + + self._logger = Logger().get_logger() + self._builder = Gtk.Builder() + self._main_window = None + + # '_filters' + self._vids_filter = ('.mkv', '.avi', '.flv', '.mov', '.m4v', '.mpg', '.wmv', '.mpeg', '.mp4', '.webm') + self._images_filter = ('.png', '.jpg', '.jpeg', '.gif') + + self._success_color = "#88cc27" + self._warning_color = "#ffa800" + self._error_color = "#ff0000" + + if not os.path.exists(self._GLADE_FILE): + self._GLADE_FILE = f"{self._USR_PATH}/Main_Window.glade" + if not os.path.exists(self._CSS_FILE): + self._CSS_FILE = f"{self._USR_PATH}/stylesheet.css" + if not os.path.exists(self._WINDOW_ICON): + self._WINDOW_ICON = f"{self._USR_PATH}/icons/{app_name.lower()}.png" + if not os.path.exists(self._DEFAULT_ICONS): + self.DEFAULT_ICONS = f"{self._USR_PATH}/icons" + + self._builder.add_from_file(self._GLADE_FILE) + + + + def create_window(self): + # Get window and connect signals + self._main_window = self._builder.get_object("Main_Window") + self.set_window_data() + + def set_window_data(self): + self._main_window.set_icon_from_file(self._WINDOW_ICON) + screen = self._main_window.get_screen() + visual = screen.get_rgba_visual() + + if visual != None and screen.is_composited(): + self._main_window.set_visual(visual) + self._main_window.set_app_paintable(True) + self._main_window.connect("draw", self.draw_area) + + # bind css file + cssProvider = Gtk.CssProvider() + cssProvider.load_from_path(self._CSS_FILE) + screen = Gdk.Screen.get_default() + styleContext = Gtk.StyleContext() + styleContext.add_provider_for_screen(screen, cssProvider, Gtk.STYLE_PROVIDER_PRIORITY_USER) + + def get_monitor_data(self): + screen = self._builder.get_object("Main_Window").get_screen() + monitors = [] + for m in range(screen.get_n_monitors()): + monitors.append(screen.get_monitor_geometry(m)) + + for monitor in monitors: + print("{}x{}|{}+{}".format(monitor.width, monitor.height, monitor.x, monitor.y)) + + return monitors + + def draw_area(self, widget, cr): + cr.set_source_rgba(0, 0, 0, 0.54) + cr.set_operator(cairo.OPERATOR_SOURCE) + cr.paint() + cr.set_operator(cairo.OPERATOR_OVER) + + + + + def get_builder(self): return self._builder + def get_logger(self): return self._logger + def get_main_window(self): return self._main_window + def get_home_path(self): return self._USER_HOME + def get_config_file(self): return self._CONFIG_FILE + def get_xscreensavers(self): return self._XSCREEN_SAVERS + + # Filter returns + def get_vids_filter(self): return self._vids_filter + def get_images_filter(self): return self._images_filter + + def get_success_color(self): return self._success_color + def get_warning_color(self): return self._warning_color + def get_error_color(self): return self._error_color diff --git a/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/__init__.py b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/__init__.py new file mode 100644 index 0000000..415301e --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/opt/GWinWrap/utils/__init__.py @@ -0,0 +1,6 @@ +""" + Utils module +""" + +from .Logger import Logger +from .Settings import Settings diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/doc/gwinwrap/copyright b/src/debs/gwinwrap-0-0-2-x64/usr/share/doc/gwinwrap/copyright new file mode 100644 index 0000000..53b78e8 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/usr/share/doc/gwinwrap/copyright @@ -0,0 +1,22 @@ +GWinWrap is copyright 2016, 2017 Maxim Stewart. +GWinWrap is currently developed by ITDominator <1itdominator@gmail.com>. + +License: GPLv2+ + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. + +See /usr/share/common-licenses/GPL-2, or + for the terms of the latest version +of the GNU General Public License. diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/Main_Window.glade b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/Main_Window.glade new file mode 100644 index 0000000..c6df58f --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/Main_Window.glade @@ -0,0 +1,882 @@ + + + + + + + inode/directory + + + + + + + + + + True + False + gtk-clear + 3 + + + True + False + gtk-quit + 3 + + + True + False + gtk-cancel + 3 + + + True + False + gtk-jump-to + 3 + + + True + False + gtk-save + 3 + + + True + False + gtk-save + 3 + + + True + False + Settings.... + gtk-properties + 3 + + + True + False + gtk-media-play + 3 + + + True + False + gtk-media-stop + 3 + + + 950 + 600 + False + GWinWrap + center + 950 + 600 + usr/share/gwinwrap/icons/gwinwrap.png + center + + + True + False + + + True + False + 15 + 15 + 15 + vertical + + + True + False + 5 + + + True + False + 15 + Note: Double click an image to view the video or image. + + + True + True + 0 + + + + + True + False + Chose Dream Scene / Image Directory + select-folder + False + Folders + Dream Scene / Image Dir + + + + False + True + 1 + + + + + True + True + True + settingsImage + True + + + + False + True + 2 + + + + + False + True + 0 + + + + + True + False + True + + + False + True + 1 + + + + + True + True + in + + + True + False + + + + True + False + vertical + 10 + 10 + True + True + + + 640 + 525 + True + False + Choose Image/Video Directory... + + + + + + 0 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + True + True + 2 + + + + + Clear + True + True + True + clearImage + True + + + + False + True + 3 + + + + + True + True + 0 + + + + + 300 + True + False + 10 + 15 + 15 + 15 + False + vertical + + + True + False + vertical + + + Use XScreenSaver + True + True + False + center + 5 + True + + + + False + True + 0 + + + + + True + True + in + + + True + False + True + XScreensaverStore + False + + + + + + + + XScreensaves + + + + 0 + + + + + + + + + True + True + 1 + + + + + True + True + 0 + + + + + True + False + False + vertical + + + True + False + vertical + + + True + False + + + True + False + 10 + 10 + Playback Resolutions + + + True + True + 0 + + + + + True + False + 10 + 10 + Position Offset + + + True + True + 1 + + + + + False + True + 0 + + + + + True + False + + + True + False + 3 + + 7680x4320 + 3840x2160 + 2048x1080 + 1920x1080 + 1440x720 + 1600x900 + 1280x720 + 800x600 + + + + True + True + 0 + + + + + True + False + + + True + True + 1 + + + + + False + True + 1 + + + + + False + True + 0 + + + + + True + False + vertical + + + True + False + 10 + 5 + Save Path + + + True + True + 0 + + + + + True + False + 0 + + .animatedBGstarter.sh + .animatedBGstarter2.sh + .animatedBGstarter3.sh + + + + True + True + 1 + + + + + False + True + 1 + + + + + + True + False + + + Save + True + True + True + True + True + saveImage + True + + + + 1 + 0 + + + + + (Re)Start + True + True + True + True + True + startImage + True + + + + 0 + 0 + + + + + Stop + True + True + True + True + True + stopImage + True + + + + 0 + 1 + + + + + Close + True + True + True + True + True + closeImage + True + + + + 1 + 1 + + + + + + + + + + + + + + + + + + + + False + True + 2 + + + + + False + False + end + 1 + + + + + False + True + 1 + 1 + + + + + + + 640 + 525 + False + 350 + True + True + helpLabel + bottom + False + + + True + False + vertical + + + True + False + + + True + True + True + Close Demo Window + closePopupImage + True + + + + False + True + end + 0 + + + + + False + True + 0 + + + + + True + False + 0 + none + + + True + False + + + + + True + True + 1 + + + + + + + 640 + 525 + False + True + True + helpLabel + bottom + + + True + False + vertical + + + True + False + bottom + + + Main Image Viewer + True + True + True + openProgImage + True + + + + False + True + 0 + + + + + True + True + True + True + + + + False + True + 1 + + + + + False + True + 0 + + + + + True + True + in + False + + + True + False + + + True + False + gtk-missing-image + 6 + + + + + + + True + True + 1 + + + + + + + 250 + False + button1 + + + True + False + vertical + + + True + False + + + True + False + folder + + + False + True + 0 + + + + + 330 + 26 + True + True + Set Custom Default Path + Set Custom Start Path + + + True + True + 1 + + + + + False + True + 0 + + + + + True + False + + + True + False + video-x-generic + + + False + True + 0 + + + + + 330 + 26 + True + True + Set Custom Video Player + Set Custom Video Player + + + True + True + 1 + + + + + False + True + 1 + + + + + True + False + + + True + False + image-x-generic + + + False + True + 0 + + + + + 330 + 26 + True + True + Set Custom Image Viewer + Set Custom Image Viewer + + + False + True + 1 + + + + + False + True + 2 + + + + + Save + True + True + True + saveImag + True + + + + False + True + 3 + + + + + + diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/dir.png b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/dir.png new file mode 100644 index 0000000..a9b5e9f Binary files /dev/null and b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/dir.png differ diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/gwinwrap.png b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/gwinwrap.png new file mode 100644 index 0000000..cdd708d Binary files /dev/null and b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/gwinwrap.png differ diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/picture.png b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/picture.png new file mode 100644 index 0000000..46f1ae6 Binary files /dev/null and b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/picture.png differ diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/video.png b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/video.png new file mode 100644 index 0000000..55afa98 Binary files /dev/null and b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/icons/video.png differ diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/settings.json b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/settings.json new file mode 100644 index 0000000..596ddd2 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/settings.json @@ -0,0 +1,9 @@ +{ + "settings":[ + { + "start_path":"/home/abaddon/LazyShare/Movies-TV-Music/Dream Scenes/Games/Halo", + "default_player":"mpv", + "default_img_viewer":"mirage" + } + ] +} \ No newline at end of file diff --git a/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/stylesheet.css b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/stylesheet.css new file mode 100644 index 0000000..c0383f6 --- /dev/null +++ b/src/debs/gwinwrap-0-0-2-x64/usr/share/gwinwrap/stylesheet.css @@ -0,0 +1,86 @@ +/* Set fm to have transparent window */ +box, +iconview, +notebook, +paned, +stack, +scrolledwindow, +treeview.view, +.content-view, +.view { + background: rgba(19, 21, 25, 0.14); + color: rgba(255, 255, 255, 1); +} + +notebook > header > tabs > tab:checked { + /* Neon Blue 00e8ff */ + background-color: rgba(0, 232, 255, 0.2); + /* Dark Bergundy */ + /* background-color: rgba(116, 0, 0, 0.25); */ + + color: rgba(255, 255, 255, 0.8); +} + +#message_view { + font: 16px "Monospace"; +} + +.view:selected, +.view:selected:hover { + box-shadow: inset 0 0 0 9999px rgba(21, 158, 167, 0.34); + color: rgba(255, 255, 255, 0.5); +} + +.alert-border { + border: 2px solid rgba(116, 0, 0, 0.64); +} + +.search-border { + border: 2px solid rgba(136, 204, 39, 1); +} + +.notebook-selected-focus { + /* Neon Blue 00e8ff border */ + border: 2px solid rgba(0, 232, 255, 0.34); + /* Dark Bergundy */ + /* border: 2px solid rgba(116, 0, 0, 0.64); */ +} + +.notebook-unselected-focus { + /* Neon Blue 00e8ff border */ + /* border: 2px solid rgba(0, 232, 255, 0.25); */ + /* Dark Bergundy */ + /* border: 2px solid rgba(116, 0, 0, 0.64); */ + /* Snow White */ + border: 2px solid rgba(255, 255, 255, 0.24); +} + + + + + +/* * { + background: rgba(0, 0, 0, 0.14); + color: rgba(255, 255, 255, 1); +} */ + +/* * selection { + background-color: rgba(116, 0, 0, 0.65); + color: rgba(255, 255, 255, 0.5); +} */ + +/* Rubberband coloring */ +/* .rubberband, +rubberband, +flowbox rubberband, +treeview.view rubberband, +.content-view rubberband, +.content-view .rubberband, +XfdesktopIconView.view .rubberband { + border: 1px solid #6c6c6c; + background-color: rgba(21, 158, 167, 0.57); +} + +XfdesktopIconView.view:active { + background-color: rgba(172, 102, 21, 1); +} */