diff --git a/source/Ox.UI/Ox.UI.js b/source/Ox.UI/Ox.UI.js index 9c04cea4..1be66b31 100644 --- a/source/Ox.UI/Ox.UI.js +++ b/source/Ox.UI/Ox.UI.js @@ -247,14 +247,14 @@ Ox.load.UI = function(options, callback) { }); } length = data.files.length; - Ox.IMAGES = data.images; - Ox.THEMES = {}; + Ox.UI.IMAGES = data.images; + Ox.UI.THEMES = {}; data.files.forEach(function(file) { path = Ox.PATH + file + '?' + Ox.VERSION; if (/\.jsonc$/.test(file)) { Ox.getJSONC(path, function(data) { var theme = /\/themes\/(\w+)\/json\//.exec(file)[1]; - Ox.THEMES[theme] = data; + Ox.UI.THEMES[theme] = data; ++counter == length && initUI(); }); } else { diff --git a/source/Ox.UI/js/Code/DocPage.js b/source/Ox.UI/js/Code/DocPage.js index 3df82314..43714825 100644 --- a/source/Ox.UI/js/Code/DocPage.js +++ b/source/Ox.UI/js/Code/DocPage.js @@ -145,8 +145,8 @@ Ox.DocPage = function(options, self) { Ox.$('') .attr({ src: isExpanded - ? Ox.getImageURL('symbolDown') - : Ox.getImageURL('symbolRight') + ? Ox.UI.getImageURL('symbolDown') + : Ox.UI.getImageURL('symbolRight') }) .css({ width: '12px', @@ -156,11 +156,11 @@ Ox.DocPage = function(options, self) { .on({ click: function() { var $this = $(this), - isExpanded = $this.attr('src') == Ox.getImageURL('symbolRight'); + isExpanded = $this.attr('src') == Ox.UI.getImageURL('symbolRight'); $this.attr({ src: isExpanded - ? Ox.getImageURL('symbolDown') - : Ox.getImageURL('symbolRight') + ? Ox.UI.getImageURL('symbolDown') + : Ox.UI.getImageURL('symbolRight') }); $('.' + className).each(function() { var $this = $(this), isHidden = false; diff --git a/source/Ox.UI/js/Code/DocPanel.js b/source/Ox.UI/js/Code/DocPanel.js index cc9542f4..adab5131 100644 --- a/source/Ox.UI/js/Code/DocPanel.js +++ b/source/Ox.UI/js/Code/DocPanel.js @@ -197,7 +197,7 @@ Ox.DocPanel = function(options, self) { self.options.showTooltips ? getTooltip(results) : null ); } else if (!Ox.endsWith(id, '/')) { - $icon = $('').attr({src: Ox.getImageURL('symbolCenter')}); + $icon = $('').attr({src: Ox.UI.getImageURL('symbolCenter')}); } return $icon; } @@ -293,7 +293,7 @@ Ox.DocPanel = function(options, self) { expanded: self.options.expanded, icon: self.options.showTests ? getIcon - : Ox.getImageURL('symbolCenter'), + : Ox.UI.getImageURL('symbolCenter'), items: treeItems, selected: self.options.selected ? [self.options.selected] : '', width: self.options.size diff --git a/source/Ox.UI/js/Code/ExamplePanel.js b/source/Ox.UI/js/Code/ExamplePanel.js index 4619ce66..1b8bd859 100644 --- a/source/Ox.UI/js/Code/ExamplePanel.js +++ b/source/Ox.UI/js/Code/ExamplePanel.js @@ -75,7 +75,7 @@ Ox.ExamplePanel = function(options, self) { }); self.$list = Ox.TreeList({ expanded: true, - icon: Ox.getImageURL('symbolCenter'), + icon: Ox.UI.getImageURL('symbolCenter'), items: treeItems, selected: self.options.selected ? [self.options.selected] : [], width: self.options.size diff --git a/source/Ox.UI/js/Core/LoadingIcon.js b/source/Ox.UI/js/Core/LoadingIcon.js index 74d40547..0ab96f79 100644 --- a/source/Ox.UI/js/Core/LoadingIcon.js +++ b/source/Ox.UI/js/Core/LoadingIcon.js @@ -19,7 +19,7 @@ Ox.LoadingIcon = function(options, self) { .options(options || {}) .addClass('OxLoadingIcon') .attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbolLoading', self.options.video ? 'videoIcon' : null ) diff --git a/source/Ox.UI/js/Core/Theme.js b/source/Ox.UI/js/Core/Theme.js index 7cfab653..263869a9 100644 --- a/source/Ox.UI/js/Core/Theme.js +++ b/source/Ox.UI/js/Core/Theme.js @@ -99,7 +99,7 @@ Ox.Theme = (function() { $('.OxColor').each(function() { var $element = $(this); if ($element.hasClass('OxColorName')) { - $element.attr({src: Ox.getImageURL( + $element.attr({src: Ox.UI.getImageURL( $element.data('OxImage'), $element.data('OxColor'), theme )}); } else { @@ -119,9 +119,9 @@ Ox.Theme = (function() { $('img').add('input[type="image"]').not('.OxColor') .each(function(element) { var $element = $(this), - data = Ox.getImageData($element.attr('src')); + data = Ox.UI.getImageData($element.attr('src')); data && $element.attr({ - src: Ox.getImageURL(data.name, data.color, theme) + src: Ox.UI.getImageURL(data.name, data.color, theme) }); }); } @@ -134,7 +134,7 @@ Ox.Theme = (function() { () -> [s] Theme names @*/ that.getThemes = function() { - return Object.keys(Ox.THEMES); + return Object.keys(Ox.UI.THEMES); }; /*@ @@ -143,7 +143,7 @@ Ox.Theme = (function() { theme Theme name @*/ that.getThemeData = function(theme) { - return Ox.THEMES[theme || Ox.Theme()]; + return Ox.UI.THEMES[theme || Ox.Theme()]; }; /*@ @@ -183,7 +183,7 @@ Ox.Theme = (function() { that.getColorImage = function(name, value, tooltip) { return (tooltip ? Ox.Element({element: '', tooltip: tooltip}) : $('')) .addClass('OxColor OxColorName') - .attr({src: Ox.getImageURL(name, value)}) + .attr({src: Ox.UI.getImageURL(name, value)}) .data({OxColor: value, OxImage: name}); }; diff --git a/source/Ox.UI/js/Core/UI.js b/source/Ox.UI/js/Core/UI.js index ce82b445..c9539b86 100644 --- a/source/Ox.UI/js/Core/UI.js +++ b/source/Ox.UI/js/Core/UI.js @@ -82,7 +82,7 @@ Ox.getImageURL = Ox.UI.getImageURL = Ox.cache(function(name, color, theme) { '#FF0000': 'symbolWarningColor' } }, - image = Ox.IMAGES[name], + image = Ox.UI.IMAGES[name], themeData, type = Ox.toDashes(name).split('-')[0]; color = color || 'default'; diff --git a/source/Ox.UI/js/Form/Button.js b/source/Ox.UI/js/Form/Button.js index a99c4fdf..337bc284 100644 --- a/source/Ox.UI/js/Form/Button.js +++ b/source/Ox.UI/js/Form/Button.js @@ -152,7 +152,7 @@ Ox.Button = function(options, self) { function setTitle() { if (self.options.type == 'image') { that.attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + self.options.title[0].toUpperCase() + self.options.title.slice(1), self.options.style == 'overlay' ? 'overlay' + ( diff --git a/source/Ox.UI/js/Form/FormPanel.js b/source/Ox.UI/js/Form/FormPanel.js index dae885a3..b6b3409c 100644 --- a/source/Ox.UI/js/Form/FormPanel.js +++ b/source/Ox.UI/js/Form/FormPanel.js @@ -31,7 +31,7 @@ Ox.FormPanel = function(options, self) { format: function(value) { return $('') .attr({ - src: Ox.getImageURL('symbolCheck') + src: Ox.UI.getImageURL('symbolCheck') }) .css({ width: '10px', diff --git a/source/Ox.UI/js/List/IconItem.js b/source/Ox.UI/js/List/IconItem.js index bf6f3cdb..94bc6538 100644 --- a/source/Ox.UI/js/List/IconItem.js +++ b/source/Ox.UI/js/List/IconItem.js @@ -46,7 +46,7 @@ Ox.IconItem = function(options, self) { infoIsObject: Ox.isObject(self.options.info), lineLength: self.options.itemWidth == 64 ? 15 : 23, lines: self.options.itemWidth == 64 ? 4 : 5, - url: Ox.UI_PATH + 'png/transparent.png' + url: Ox.UI.PATH + 'png/transparent.png' }); self.title = formatText(self.options.title, self.lines - 1 - self.infoIsObject, self.lineLength); diff --git a/source/Ox.UI/js/List/TableList.js b/source/Ox.UI/js/List/TableList.js index e5d3f0af..4f308b53 100644 --- a/source/Ox.UI/js/List/TableList.js +++ b/source/Ox.UI/js/List/TableList.js @@ -253,7 +253,7 @@ Ox.TableList = function(options, self) { tooltip: self.options.clearButtonTooltip }) .addClass('OxClear') - .attr({src: Ox.getImageURL('symbolClose')}) + .attr({src: Ox.UI.getImageURL('symbolClose')}) .css(Ox.UI.SCROLLBAR_SIZE == 16 ? { paddingLeft: '4px', paddingRight: '2px', @@ -467,7 +467,7 @@ Ox.TableList = function(options, self) { if (column.titleImage) { self.$titleImages[i] = $(''). attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + Ox.toTitleCase(column.titleImage) ) }) @@ -478,7 +478,7 @@ Ox.TableList = function(options, self) { if (column.operator) { self.$orderImages[i] = $('') .attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + (column.operator == '+' ? 'Up' : 'Down'), 'selected' ) @@ -909,7 +909,7 @@ Ox.TableList = function(options, self) { }); if (self.visibleColumns[pos].titleImage) { self.$titleImages[pos].attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + Ox.toTitleCase(self.visibleColumns[pos].titleImage), isSelected ? 'selected' : '' ) @@ -950,16 +950,16 @@ Ox.TableList = function(options, self) { // FIXME: not yet used that.$body.find('img').each(function(i, element) { var $element = $(element), - data = Ox.getImageData($element.attr('src')); + data = Ox.UI.getImageData($element.attr('src')); if (data && data.color == 'selected') { - $element.attr({src: Ox.getImageURL(data.name, 'default')}); + $element.attr({src: Ox.UI.getImageURL(data.name, 'default')}); } }); that.$body.find('.OxSelected img').each(function(i, element) { var $element = $(element), - data = Ox.getImageData($element.attr('src')); + data = Ox.UI.getImageData($element.attr('src')); if (data && data.color == 'default') { - $element.attr({src: Ox.getImageURL(data.name, 'selected')}); + $element.attr({src: Ox.UI.getImageURL(data.name, 'selected')}); } }); } @@ -969,7 +969,7 @@ Ox.TableList = function(options, self) { pos = getColumnPositionById(id); if (pos > -1) { self.$orderImages[pos].attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + (operator == '+' ? 'Up' : 'Down'), 'selected' ) diff --git a/source/Ox.UI/js/List/TreeList.js b/source/Ox.UI/js/List/TreeList.js index 73f5cda8..8ab9eb40 100644 --- a/source/Ox.UI/js/List/TreeList.js +++ b/source/Ox.UI/js/List/TreeList.js @@ -128,7 +128,7 @@ Ox.TreeList = function(options, self) { $icon = $('').attr({src: self.options.icon}); } } else { - $icon = $('').attr({src: Ox.getImageURL( + $icon = $('').attr({src: Ox.UI.getImageURL( 'symbol' + (expanded ? 'Down' : 'Right') )}); } diff --git a/source/Ox.UI/js/Video/BlockVideoTimeline.js b/source/Ox.UI/js/Video/BlockVideoTimeline.js index d27db5ce..5cafbd36 100644 --- a/source/Ox.UI/js/Video/BlockVideoTimeline.js +++ b/source/Ox.UI/js/Video/BlockVideoTimeline.js @@ -81,7 +81,7 @@ Ox.BlockVideoTimeline = function(options, self) { self.$positionMarker = Ox.$('') .attr({ - src: Ox.getImageURL('markerPosition') + src: Ox.UI.getImageURL('markerPosition') }) .addClass('OxMarkerPosition') .appendTo(that); @@ -94,7 +94,7 @@ Ox.BlockVideoTimeline = function(options, self) { self.$pointMarker[point] = Ox.$('') .addClass('OxMarkerPoint' + titlecase) .attr({ - src: Ox.getImageURL('marker' + titlecase) + src: Ox.UI.getImageURL('marker' + titlecase) }) .appendTo(that); setPointMarker(point); diff --git a/source/Ox.UI/js/Video/LargeVideoTimeline.js b/source/Ox.UI/js/Video/LargeVideoTimeline.js index cbb9cb82..c264ec27 100644 --- a/source/Ox.UI/js/Video/LargeVideoTimeline.js +++ b/source/Ox.UI/js/Video/LargeVideoTimeline.js @@ -98,10 +98,10 @@ Ox.LargeVideoTimeline = function(options, self) { setTimeout(function() { var $cut = $('') .addClass('OxCut') - .attr({src: Ox.getImageURL('markerCut')}), + .attr({src: Ox.UI.getImageURL('markerCut')}), $chapter = $('') .addClass('OxChapter') - .attr({src: Ox.getImageURL('markerChapter')}), + .attr({src: Ox.UI.getImageURL('markerChapter')}), chapters = self.options.chapters.slice(1).map(function(chapter) { return chapter.position; }); @@ -115,7 +115,7 @@ Ox.LargeVideoTimeline = function(options, self) { self.$markerPosition = $('') .addClass('OxMarkerPosition') - .attr({src: Ox.getImageURL('markerPosition')}) + .attr({src: Ox.UI.getImageURL('markerPosition')}) .appendTo(that); setMarker(); @@ -124,7 +124,7 @@ Ox.LargeVideoTimeline = function(options, self) { var titlecase = Ox.toTitleCase(point); self.$pointMarker[point] = $('') .addClass('OxMarkerPoint' + titlecase) - .attr({src: Ox.getImageURL('marker' + titlecase)}) + .attr({src: Ox.UI.getImageURL('marker' + titlecase)}) .appendTo(self.$timeline); setPointMarker(point); }); diff --git a/source/Ox.UI/js/Video/SmallVideoTimeline.js b/source/Ox.UI/js/Video/SmallVideoTimeline.js index bc7565db..11367f0b 100644 --- a/source/Ox.UI/js/Video/SmallVideoTimeline.js +++ b/source/Ox.UI/js/Video/SmallVideoTimeline.js @@ -127,7 +127,7 @@ Ox.SmallVideoTimeline = function(options, self) { self.$positionMarker = $('') .addClass('OxMarkerPosition') .attr({ - src: Ox.getImageURL('markerPosition') + src: Ox.UI.getImageURL('markerPosition') }) .appendTo(that); } @@ -140,7 +140,7 @@ Ox.SmallVideoTimeline = function(options, self) { self.$pointMarker[point] = $('') .addClass('OxMarkerPoint' + titlecase) .attr({ - src: Ox.getImageURL('marker' + titlecase) + src: Ox.UI.getImageURL('marker' + titlecase) }) .appendTo(that); setPointMarker(point); diff --git a/source/Ox.UI/js/Video/VideoPlayer.js b/source/Ox.UI/js/Video/VideoPlayer.js index 46770b1a..0080dbd2 100644 --- a/source/Ox.UI/js/Video/VideoPlayer.js +++ b/source/Ox.UI/js/Video/VideoPlayer.js @@ -552,7 +552,7 @@ Ox.VideoPlayer = function(options, self) { self.$playIcon = $('') .addClass('OxPlayIcon OxVideo') .attr({ - src: Ox.getImageURL('symbol' + ( + src: Ox.UI.getImageURL('symbol' + ( self.options.paused ? 'Play' : 'Pause' ), 'videoIcon') }) @@ -572,7 +572,7 @@ Ox.VideoPlayer = function(options, self) { }) .addClass('OxCensoredIcon OxVideo') .attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + self.options.censoredIcon, 'videoIcon' ) }) @@ -609,7 +609,7 @@ Ox.VideoPlayer = function(options, self) { self.$pointMarker[point][edge] = $('') .addClass('OxPointMarker OxPointMarker' + titleCase) .attr({ - src: Ox.getImageURL('marker' + titleCase) + src: Ox.UI.getImageURL('marker' + titleCase) }) .appendTo(self.$videoContainer); }); @@ -2665,7 +2665,7 @@ Ox.VideoPlayer = function(options, self) { function togglePlayIcon() { self.$playIcon.attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + (self.options.paused ? 'Play' : 'Pause' ), 'videoIcon') }); diff --git a/source/Ox.UI/js/Video/VideoPlayerMenu.js b/source/Ox.UI/js/Video/VideoPlayerMenu.js index df3e1def..783eb363 100644 --- a/source/Ox.UI/js/Video/VideoPlayerMenu.js +++ b/source/Ox.UI/js/Video/VideoPlayerMenu.js @@ -24,7 +24,7 @@ Ox.VideoPlayerMenu = function(options, self) { return $item.data().group == group; }).forEach(function($item) { $($item.children()[1]).attr({ - src: Ox.getImageURL('symbol' + ( + src: Ox.UI.getImageURL('symbol' + ( $item.data().id == id ? 'Check' : 'None' )) }); @@ -62,7 +62,7 @@ Ox.VideoPlayerMenu = function(options, self) { } $('
').html(item.title).appendTo($item); $('').attr({ - src: Ox.getImageURL( + src: Ox.UI.getImageURL( 'symbol' + (item.checked ? 'Check' : 'None') ) }).appendTo($item);