From 918ed9fd995cc3e958bb0d48c8d234717facf181 Mon Sep 17 00:00:00 2001
From: tof <>
Date: Tue, 4 Sep 2007 08:56:24 +0000
Subject: Merge TSlider component from 3.2-dev branch.
---
.gitattributes | 7 +
HISTORY | 1 +
.../pages/Controls/Samples/TSlider/Home.page | 40 ++
.../pages/Controls/Samples/TSlider/Home.php | 19 +
.../protected/pages/Controls/Slider.page | 55 ++
.../protected/pages/Controls/Standard.page | 4 +
.../pages/GettingStarted/NewFeatures.page | 3 +-
framework/Exceptions/messages/messages.txt | 5 +-
framework/Web/Javascripts/source/packages.php | 3 +-
.../Javascripts/source/prado/controls/slider.js | 28 +
framework/Web/UI/WebControls/TSlider.php | 616 +++++++++++++++++++++
framework/Web/UI/WebControls/assets/TSlider.css | 55 ++
.../Web/UI/WebControls/assets/TSliderHandle.png | Bin 0 -> 717 bytes
13 files changed, 833 insertions(+), 3 deletions(-)
create mode 100644 demos/quickstart/protected/pages/Controls/Samples/TSlider/Home.page
create mode 100644 demos/quickstart/protected/pages/Controls/Samples/TSlider/Home.php
create mode 100644 demos/quickstart/protected/pages/Controls/Slider.page
create mode 100644 framework/Web/Javascripts/source/prado/controls/slider.js
create mode 100644 framework/Web/UI/WebControls/TSlider.php
create mode 100755 framework/Web/UI/WebControls/assets/TSlider.css
create mode 100644 framework/Web/UI/WebControls/assets/TSliderHandle.png
diff --git a/.gitattributes b/.gitattributes
index f48d1084..67d3d6c5 100644
--- a/.gitattributes
+++ b/.gitattributes
@@ -1462,6 +1462,8 @@ demos/quickstart/protected/pages/Controls/Samples/TRepeater/Sample5.php -text
demos/quickstart/protected/pages/Controls/Samples/TRequiredFieldValidator/Home.page -text
demos/quickstart/protected/pages/Controls/Samples/TRequiredFieldValidator/Home.php -text
demos/quickstart/protected/pages/Controls/Samples/TSafeHtml/Home.page -text
+demos/quickstart/protected/pages/Controls/Samples/TSlider/Home.page -text
+demos/quickstart/protected/pages/Controls/Samples/TSlider/Home.php -text
demos/quickstart/protected/pages/Controls/Samples/TStatements/Home.page -text
demos/quickstart/protected/pages/Controls/Samples/TTabPanel/Home.page -text
demos/quickstart/protected/pages/Controls/Samples/TTabPanel/Home.php -text
@@ -1484,6 +1486,7 @@ demos/quickstart/protected/pages/Controls/Samples/TWizard/Sample4.php -text
demos/quickstart/protected/pages/Controls/Samples/TWizard/Sample5.page -text
demos/quickstart/protected/pages/Controls/Samples/TWizard/Sample5.php -text
demos/quickstart/protected/pages/Controls/Samples/config.xml -text
+demos/quickstart/protected/pages/Controls/Slider.page -text
demos/quickstart/protected/pages/Controls/Standard.page -text
demos/quickstart/protected/pages/Controls/Statements.page -text
demos/quickstart/protected/pages/Controls/TabPanel.page -text
@@ -2422,6 +2425,7 @@ framework/Web/Javascripts/source/prado/colorpicker/target_black.gif -text
framework/Web/Javascripts/source/prado/colorpicker/target_white.gif -text
framework/Web/Javascripts/source/prado/controls/controls.js -text
framework/Web/Javascripts/source/prado/controls/keyboard.js -text
+framework/Web/Javascripts/source/prado/controls/slider.js -text
framework/Web/Javascripts/source/prado/controls/tabpanel.js -text
framework/Web/Javascripts/source/prado/datepicker/calendar.png -text
framework/Web/Javascripts/source/prado/datepicker/datepicker.js -text
@@ -2569,6 +2573,7 @@ framework/Web/UI/WebControls/TRepeater.php -text
framework/Web/UI/WebControls/TRepeaterItemRenderer.php -text
framework/Web/UI/WebControls/TRequiredFieldValidator.php -text
framework/Web/UI/WebControls/TSafeHtml.php -text
+framework/Web/UI/WebControls/TSlider.php -text
framework/Web/UI/WebControls/TStatements.php -text
framework/Web/UI/WebControls/TStyle.php -text
framework/Web/UI/WebControls/TTabPanel.php -text
@@ -2588,6 +2593,8 @@ framework/Web/UI/WebControls/TWebControlAdapter.php -text
framework/Web/UI/WebControls/TWizard.php -text
framework/Web/UI/WebControls/TWizardNavigationButtonStyle.php -text
framework/Web/UI/WebControls/TXmlTransform.php -text
+framework/Web/UI/WebControls/assets/TSlider.css -text
+framework/Web/UI/WebControls/assets/TSliderHandle.png -text svneol=unset#image/png
framework/Web/UI/WebControls/assets/captcha.php -text
framework/Web/UI/WebControls/assets/keyboard.css -text
framework/Web/UI/WebControls/assets/tabpanel.css -text
diff --git a/HISTORY b/HISTORY
index d7cf7ba1..1ddc0cee 100644
--- a/HISTORY
+++ b/HISTORY
@@ -23,6 +23,7 @@ NEW: Ticket#680 - Added TCacheHttpSession (Carl, Qiang)
NEW: Added TTabPanel (Qiang)
NEW: Added TKeyboard (Qiang)
NEW: Added TCaptcha and TCaptchaValidator (Qiang)
+NEW: Added TSlider (Christophe)
NEW: Added Indonesian translation to QuickStart, requirements and error messages (Zaenal Mutaqin)
NEW: Added French translation to the blog tutorial (Eric Marchetti)
diff --git a/demos/quickstart/protected/pages/Controls/Samples/TSlider/Home.page b/demos/quickstart/protected/pages/Controls/Samples/TSlider/Home.page
new file mode 100644
index 00000000..7670f9d3
--- /dev/null
+++ b/demos/quickstart/protected/pages/Controls/Samples/TSlider/Home.page
@@ -0,0 +1,40 @@
+
+TSlider displays a slider for numeric input purpose. A slider consists of a track
+which define the range of possible value, and a handle which can slide on the track, to select
+a value in the range. The track can be either Horizontal or Vertical, depending of the Direction
+property. By default, it's horizontal.
+
+The range boundaries are defined by MinValue and MaxValue properties.
+The default range is from 0 to 100.
+The StepSize property can be used to define the step between 2 values inside the range.
+Notice that this step will be recomputed if there is more than 200 values between the range boundaries.
+You can also provide the allowed values by setting the Values array.
+
+The handle sub-properties can be accessed by Handle property. You can also provide your own control
+for the handle, using HandleClass property. Note that this class must be a subclass of
+TSliderHandle
+
+The TSlider control can be easily customized using CssClasses. You can provide your own css file, using the
+CssUrl property.
+The css class for TSlider can be set by the CssClass property. Defaults values are 'hslider' for
+an Horizontal slider, or 'vslider' for a Vertical one.
+The css class for the Handle can be set by the Handle.CssClass subproperty. Defaults is 'handle', which just
+draw a red block as a cursor. 'handle-image' css class is also provided for your convenience, which display an image
+as the handle.
+
+If AutoPostBack property is true, postback is performed as soon as the value changed.
+
+TSlider raises the onValueChanged event when the value of the slider has changed during postback.
+
+You can also attach ClientSide javascript events handler to the slider :
+TSlider Sample
+
+
+
+
+
+
+Simple horizontal slider, with no events handler attached
+
+
+
+
+Horizontal slider from -50 to 50, with image handle, Javascript 'onSlide' handler, ServerSide 'onSliderChanged' handler, initial value and autopostback=true
+
+
+
+
+Vertical slider from 0 to 1, with image handle, Javascript 'onSlide' handler, ServerSide 'onSliderChanged' handler, StepSize, and no autopostback
+
+
+ TSlider
+
+
+