all files / app/main/ui/theme-colors/ theme-colors.controller.js

50% Statements 4/8
100% Branches 0/0
33.33% Functions 1/3
50% Lines 4/8
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 32 33 34 35 36                                                                
(function ()
{
    'use strict';
 
    angular
        .module('app.ui.theme-colors')
        .controller('ThemeColorsController', ThemeColorsController);
 
    /** @ngInject */
    function ThemeColorsController(fuseTheming, $mdDialog, $document)
    {
        var vm = this;
        // Data
        vm.themes = fuseTheming.themes;
 
        // Methods
        vm.createTheme = createTheme;
        //////////
 
        function createTheme(ev)
        {
            $mdDialog.show({
                controller         : 'CustomThemeDialogController',
                controllerAs       : 'vm',
                templateUrl        : 'app/main/ui/theme-colors/dialogs/custom-theme/custom-theme-dialog.html',
                parent             : angular.element($document.body),
                targetEvent        : ev,
                clickOutsideToClose: true
            });
        }
 
    }
})();