Example #1
0
def saveAllRecords():
    global recordContents, isSetTitle
    if "isSaveActions" not in uni.MySettings.keys() or uni.getBoolValue("isSaveActions"):
        if fu.isFile(fu.recordFilePath) is False:
            create()
        setRecordType(1)
        fu.addToFile(fu.recordFilePath, recordContents)
        restoreRecordType()
    recordContents = ""
    isSetTitle = False
Example #2
0
def saveAllRecords():
    global recordContents, isSetTitle
    if "isSaveActions" not in uni.MySettings.keys() or uni.getBoolValue(
            "isSaveActions"):
        if fu.isFile(fu.recordFilePath) is False:
            create()
        setRecordType(1)
        fu.addToFile(fu.recordFilePath, recordContents)
        restoreRecordType()
    recordContents = ""
    isSetTitle = False
Example #3
0
def read(_recordFilePath=None):
    if _recordFilePath is None:
        _recordFilePath = fu.recordFilePath
    if fu.isFile(_recordFilePath):
        return fu.readFromFile(_recordFilePath, "utf-8")
    else:
        create()
        setRecordType(1)
        fu.addToFile(_recordFilePath, recordContents)
        restoreRecordType()
        return recordContents
Example #4
0
def read(_recordFilePath=None):
    if _recordFilePath is None:
        _recordFilePath = fu.recordFilePath
    if fu.isFile(_recordFilePath):
        return fu.readFromFile(_recordFilePath, "utf-8")
    else:
        create()
        setRecordType(1)
        fu.addToFile(_recordFilePath, recordContents)
        restoreRecordType()
        return recordContents