ElectronSettings
Constructor Summary
Public Constructor | ||
public |
|
Member Summary
Public Members | ||
public |
CURRENTPROJECTDIR_FIELD: string |
|
public |
DOWNLOAD_PATH: string |
|
public |
MAIN_CONFIG_NAME: string |
|
public |
OPEN_DEV_TOOLS_FIELD: string |
|
public |
PATCHID_FIELD: string |
|
public |
PROJECTFILE_FIELD: string |
|
public |
RECENT_PROJECTS_FIELD: string |
|
public |
SESSION_PARTITION: string |
|
public |
STORAGEDIR_FIELD: string |
|
public |
USER_SETTINGS_FIELD: string |
|
public |
WINDOW_BOUNDS: string |
|
public |
WINDOW_ZOOM_FACTOR: string |
|
public |
data: * |
|
public |
opts: {} |
Private Members | ||
private |
|
|
private |
_log: * |
Method Summary
Public Methods | ||
public |
addToRecentProjects(projectFile: *, project: *) |
|
public |
get(key: *): * |
|
public |
getBuildInfo(): {"updateWarning": *, "core": *, "ui": *, "api": *} |
|
public |
getCurrentProject(): * |
|
public |
getCurrentProjectDir(): * |
|
public |
|
|
public |
getCurrentUser(): {"username": *, "_id": *, "profile_theme": string, "isStaff": *, "usernameLowercase": *, "isAdmin": *, "theme": string, "created": *} |
|
public |
getDownloadPath(): * |
|
public |
getProjectFromFile(projectFile: *): * |
|
public |
getRecentProjectFile(projectId: *): * |
|
public |
getRecentProjects(): * |
|
public |
getUserSetting(key: *, defaultValue: undefined): * |
|
public |
refresh() |
|
public |
replaceInRecentProjects(oldFile: *, newFile: *, newProject: *): * |
|
public |
set(key: *, val: *, silent: *) |
|
public |
setProject(projectFile: *, newProject: *) |
|
public |
setRecentProjects(recents: *): * |
|
public |
setUserSettings(value: *) |
Private Methods | ||
private |
_parseDataFile(filePath: *, defaults: *): * |
|
private |
_setCurrentProject(projectFile: *, project: *) |
|
private |
_setCurrentProjectDir(value: *) |
|
private |
_setCurrentProjectFile(value: *) |
|
private |
_toRecentProjectInfo(project: *): {"_id": *, "shortId": *, "name": *, "screenshot": *, "created": *, "updated": *} |
|
private |
|
Public Constructors
public constructor() source
Public Members
public CURRENTPROJECTDIR_FIELD: string source
public DOWNLOAD_PATH: string source
public MAIN_CONFIG_NAME: string source
public OPEN_DEV_TOOLS_FIELD: string source
public PATCHID_FIELD: string source
public PROJECTFILE_FIELD: string source
public RECENT_PROJECTS_FIELD: string source
public SESSION_PARTITION: string source
public STORAGEDIR_FIELD: string source
public USER_SETTINGS_FIELD: string source
public WINDOW_BOUNDS: string source
public WINDOW_ZOOM_FACTOR: string source
public data: * source
public opts: {} source
Private Members
private _currentProject: * source
private _log: * source
Public Methods
public addToRecentProjects(projectFile: *, project: *) source
Params:
Name | Type | Attribute | Description |
projectFile | * | ||
project | * |
public getBuildInfo(): {"updateWarning": *, "core": *, "ui": *, "api": *} source
Return:
{"updateWarning": *, "core": *, "ui": *, "api": *} |
public getCurrentUser(): {"username": *, "_id": *, "profile_theme": string, "isStaff": *, "usernameLowercase": *, "isAdmin": *, "theme": string, "created": *} source
Return:
{"username": *, "_id": *, "profile_theme": string, "isStaff": *, "usernameLowercase": *, "isAdmin": *, "theme": string, "created": *} |
public getProjectFromFile(projectFile: *): * source
Params:
Name | Type | Attribute | Description |
projectFile | * |
Return:
* |
public getRecentProjectFile(projectId: *): * source
Params:
Name | Type | Attribute | Description |
projectId | * |
Return:
* |
public getUserSetting(key: *, defaultValue: undefined): * source
Params:
Name | Type | Attribute | Description |
key | * | ||
defaultValue | undefined |
|
Return:
* |
public refresh() source
public replaceInRecentProjects(oldFile: *, newFile: *, newProject: *): * source
Params:
Name | Type | Attribute | Description |
oldFile | * | ||
newFile | * | ||
newProject | * |
Return:
* |
public set(key: *, val: *, silent: *) source
Params:
Name | Type | Attribute | Description |
key | * | ||
val | * | ||
silent | * |
public setProject(projectFile: *, newProject: *) source
Params:
Name | Type | Attribute | Description |
projectFile | * | ||
newProject | * |
public setRecentProjects(recents: *): * source
Params:
Name | Type | Attribute | Description |
recents | * |
Return:
* |
public setUserSettings(value: *) source
Params:
Name | Type | Attribute | Description |
value | * |
Private Methods
private _parseDataFile(filePath: *, defaults: *): * source
Params:
Name | Type | Attribute | Description |
filePath | * | ||
defaults | * |
Return:
* |
private _setCurrentProject(projectFile: *, project: *) source
Params:
Name | Type | Attribute | Description |
projectFile | * | ||
project | * |
private _setCurrentProjectDir(value: *) source
Params:
Name | Type | Attribute | Description |
value | * |
private _setCurrentProjectFile(value: *) source
Params:
Name | Type | Attribute | Description |
value | * |
private _toRecentProjectInfo(project: *): {"_id": *, "shortId": *, "name": *, "screenshot": *, "created": *, "updated": *} source
Params:
Name | Type | Attribute | Description |
project | * |
Return:
{"_id": *, "shortId": *, "name": *, "screenshot": *, "created": *, "updated": *} |