Skip to content

Commit

Permalink
FLUID-4547: Removing the constants for control type - this will chang…
Browse files Browse the repository at this point in the history
…e to being a subcomponents instead of string based conditional code paths.
  • Loading branch information
michelled committed Nov 30, 2011
1 parent 8ef88c7 commit 9a7cf0f
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions js/VideoPlayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,6 @@ https://source.fluidproject.org/svn/LICENSE.txt
(function ($) {
fluid.setLogging(false);

fluid.controls = {
CUSTOM: "custom",
NATIVE: "native",
NONE: "none"
};

var bindKeyboardControl = function (that) {
var opts = {
additionalBindings: [{
Expand Down Expand Up @@ -177,7 +171,7 @@ https://source.fluidproject.org/svn/LICENSE.txt
},
keyBindings: defaultKeys,
produceTree: "fluid.videoPlayer.produceTree",
controls: fluid.controls.CUSTOM,
controls: "custom",
model: {
states: {
play: false,
Expand Down Expand Up @@ -221,7 +215,7 @@ https://source.fluidproject.org/svn/LICENSE.txt
};
}
if (!($.browser.msie && $.browser.version < 9)) {
if (that.options.controls === fluid.controls.CUSTOM) {
if (that.options.controls === "custom") {
tree.controllers = {
decorators: [{
type: "fluid",
Expand All @@ -231,7 +225,7 @@ https://source.fluidproject.org/svn/LICENSE.txt
func: "fluid.videoPlayer.eventBinderControllers"
}]
};
} else if (that.options.controls === fluid.controls.NATIVE) {
} else if (that.options.controls === "native") {
tree.video.decorators.push({
type: "attrs",
attributes: {
Expand Down

0 comments on commit 9a7cf0f

Please sign in to comment.