mirror of
https://github.com/zero-peak/ZeroOmega.git
synced 2025-01-22 15:08:12 -05:00
Refreshing the page in builtin profile bug #71
This commit is contained in:
parent
c828be3984
commit
8740559d28
@ -2,14 +2,24 @@ angular.module('omega').controller 'BuiltinCtrl', ($scope, $stateParams,
|
||||
$location, $rootScope,
|
||||
$timeout, $state, $modal,
|
||||
builtinProfiles, profileColorPalette,
|
||||
getAttachedName, getParentName, getVirtualTarget
|
||||
getAttachedName, getParentName, getVirtualTarget,
|
||||
omegaTarget
|
||||
) ->
|
||||
customBuiltinProfiles = Object.assign(
|
||||
{}, builtinProfiles, $rootScope.options['-builtinProfiles']
|
||||
|
||||
customBuiltinProfiles = {}
|
||||
|
||||
decorateBuiltinProfile = (newOptions) ->
|
||||
Object.assign(
|
||||
customBuiltinProfiles,
|
||||
builtinProfiles,
|
||||
newOptions?['-builtinProfiles']
|
||||
)
|
||||
#$rootScope.options['-builtinProfiles'] = customBuiltinProfiles
|
||||
$scope.systemProfile = customBuiltinProfiles['+system']
|
||||
$scope.directProfile = customBuiltinProfiles['+direct']
|
||||
|
||||
omegaTarget.addOptionsChangeCallback decorateBuiltinProfile
|
||||
|
||||
decorateBuiltinProfile($rootScope.options)
|
||||
$scope.moveColor = (color, key) ->
|
||||
customBuiltinProfiles[key].color = color
|
||||
# make sure options watcher watch value changed
|
||||
|
Loading…
Reference in New Issue
Block a user