From deed629adc51a8ceda20f37d4a1fb7af80667e35 Mon Sep 17 00:00:00 2001 From: Balazs Birtalan Date: Wed, 17 May 2023 10:34:48 +0000 Subject: [PATCH] Notepad++ generated in local folder (no need) --- base.py.bak | 47 ----------------------------------------------- 1 file changed, 47 deletions(-) delete mode 100644 base.py.bak diff --git a/base.py.bak b/base.py.bak deleted file mode 100644 index 1b5a350..0000000 --- a/base.py.bak +++ /dev/null @@ -1,47 +0,0 @@ -import sys -import os -import configparser -from mouseevents import MouseEvents -from pynput import mouse -from sightfactory import SightFactory -from PyQt6.QtWidgets import QApplication -from pynput.mouse import Controller - -def init(): - global data, sights, mousectrl, app - #init the basic values - app = QApplication(sys.argv) - mousectrl = Controller() - sights = SightFactory() - data = {} - data["move"] = False - data["active_sight"] = "main" - data["sight_processes"] = {} - data["mouse_distance_x"] = 0 - data["mouse_distance_y"] = 0 - data["base_dir"]=os.path.abspath(os.getcwd())+os.path.sep - data["template_dir"]=data["base_dir"]+"place"+os.path.sep+"templates"+os.path.sep - #LOAD the template config content - loadConfigTemplate() - #Events - mouseevent = MouseEvents() - start() - -def loadConfigTemplate(): - config = configparser.ConfigParser() - config.sections() - config.read(data["template_dir"]+"config.ini") - if "DEFAULT" in config: - data["default_template"] = config["DEFAULT"]["default_template"] - data["default_template_dir"] = data["template_dir"]+data["default_template"]+os.path.sep - print("Template config is loaded!") - else: - print("Missing 'DEFAULT' data from the templates config.ini folder. It can't start!") - -def start(): - # Creating the main Sight - sights.create("main","main"); - sights.processes(); - sights.show("main"); - - app.exec() \ No newline at end of file