-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathKeyMapperSaveLoadDummy.py
31 lines (28 loc) · 1.71 KB
/
KeyMapperSaveLoadDummy.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
##################################################################
## ##
## A pair of convenience functions to allow KeyMapper to be ##
## used without frequent error-dialogues ##
## ##
##################################################################
## ##
## Original version written by ##
## Ian Eborn (Thaumaturge) in 2019 ##
## ##
##################################################################
## ##
## This code is free for both commercial and private use. ##
## Please leave the above credits in any subsequent versions ##
## This module and related files are offered as-is, without any ##
## warranty, with any and all defects or errors. ##
## ##
##################################################################
class SaveLoadDummy():
firstCallback = True
@staticmethod
def saveKeyMapping(keySaveData, axisSaveData, bindingFilename):
if SaveLoadDummy.firstCallback:
SaveLoadDummy.firstCallback = False
raise(IOError("Warning:\n\nUsing dummy save- and load- callbacks.\n\nBindings and profiles will not be saved or loaded!"))
@staticmethod
def loadKeyMapping(bindingFilename):
raise(IOError("Warning:\n\nUsing dummy save- and load- callbacks.\n\nBindings and profiles will not be saved or loaded!"))