Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Rotua Panjaitan
yii2
Commits
c79965ce
Commit
c79965ce
authored
Dec 15, 2013
by
Qiang Xue
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Renamed yii\jui\Widget::clientEventsMap to clientEventMap
parent
7d1c4637
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
10 deletions
+9
-10
Slider.php
extensions/yii/jui/Slider.php
+2
-3
SliderInput.php
extensions/yii/jui/SliderInput.php
+2
-3
Spinner.php
extensions/yii/jui/Spinner.php
+1
-1
Widget.php
extensions/yii/jui/Widget.php
+3
-3
CHANGELOG.md
framework/CHANGELOG.md
+1
-0
No files found.
extensions/yii/jui/Slider.php
View file @
c79965ce
...
@@ -26,7 +26,7 @@ use yii\helpers\Html;
...
@@ -26,7 +26,7 @@ use yii\helpers\Html;
*/
*/
class
Slider
extends
Widget
class
Slider
extends
Widget
{
{
protected
$clientEvent
s
Map
=
[
protected
$clientEventMap
=
[
'change'
=>
'slidechange'
,
'change'
=>
'slidechange'
,
'create'
=>
'slidecreate'
,
'create'
=>
'slidecreate'
,
'slide'
=>
'slide'
,
'slide'
=>
'slide'
,
...
@@ -42,4 +42,4 @@ class Slider extends Widget
...
@@ -42,4 +42,4 @@ class Slider extends Widget
echo
Html
::
tag
(
'div'
,
''
,
$this
->
options
);
echo
Html
::
tag
(
'div'
,
''
,
$this
->
options
);
$this
->
registerWidget
(
'slider'
,
SliderAsset
::
className
());
$this
->
registerWidget
(
'slider'
,
SliderAsset
::
className
());
}
}
}
}
\ No newline at end of file
extensions/yii/jui/SliderInput.php
View file @
c79965ce
...
@@ -43,7 +43,7 @@ use yii\helpers\Html;
...
@@ -43,7 +43,7 @@ use yii\helpers\Html;
*/
*/
class
SliderInput
extends
InputWidget
class
SliderInput
extends
InputWidget
{
{
protected
$clientEvent
s
Map
=
[
protected
$clientEventMap
=
[
'change'
=>
'slidechange'
,
'change'
=>
'slidechange'
,
'create'
=>
'slidecreate'
,
'create'
=>
'slidecreate'
,
'slide'
=>
'slide'
,
'slide'
=>
'slide'
,
...
@@ -76,4 +76,4 @@ class SliderInput extends InputWidget
...
@@ -76,4 +76,4 @@ class SliderInput extends InputWidget
$this
->
registerWidget
(
'slider'
,
SliderAsset
::
className
());
$this
->
registerWidget
(
'slider'
,
SliderAsset
::
className
());
$this
->
getView
()
->
registerJs
(
'$("#'
.
$inputId
.
'").val($("#'
.
$this
->
id
.
'").slider("value"));'
);
$this
->
getView
()
->
registerJs
(
'$("#'
.
$inputId
.
'").val($("#'
.
$this
->
id
.
'").slider("value"));'
);
}
}
}
}
\ No newline at end of file
extensions/yii/jui/Spinner.php
View file @
c79965ce
...
@@ -38,7 +38,7 @@ use yii\helpers\Html;
...
@@ -38,7 +38,7 @@ use yii\helpers\Html;
*/
*/
class
Spinner
extends
InputWidget
class
Spinner
extends
InputWidget
{
{
protected
$clientEvent
s
Map
=
[
protected
$clientEventMap
=
[
'spin'
=>
'spin'
,
'spin'
=>
'spin'
,
];
];
...
...
extensions/yii/jui/Widget.php
View file @
c79965ce
...
@@ -46,7 +46,7 @@ class Widget extends \yii\base\Widget
...
@@ -46,7 +46,7 @@ class Widget extends \yii\base\Widget
* @var array event names mapped to what should be specified in .on(
* @var array event names mapped to what should be specified in .on(
* If empty, it is assumed that event passed to clientEvents is prefixed with widget name.
* If empty, it is assumed that event passed to clientEvents is prefixed with widget name.
*/
*/
protected
$clientEvent
s
Map
=
[];
protected
$clientEventMap
=
[];
/**
/**
* Initializes the widget.
* Initializes the widget.
...
@@ -97,8 +97,8 @@ class Widget extends \yii\base\Widget
...
@@ -97,8 +97,8 @@ class Widget extends \yii\base\Widget
$id
=
$this
->
options
[
'id'
];
$id
=
$this
->
options
[
'id'
];
$js
=
[];
$js
=
[];
foreach
(
$this
->
clientEvents
as
$event
=>
$handler
)
{
foreach
(
$this
->
clientEvents
as
$event
=>
$handler
)
{
if
(
isset
(
$this
->
clientEvent
s
Map
[
$event
]))
{
if
(
isset
(
$this
->
clientEventMap
[
$event
]))
{
$eventName
=
$this
->
clientEvent
s
Map
[
$event
];
$eventName
=
$this
->
clientEventMap
[
$event
];
}
else
{
}
else
{
$eventName
=
$name
.
$event
;
$eventName
=
$name
.
$event
;
}
}
...
...
framework/CHANGELOG.md
View file @
c79965ce
...
@@ -17,6 +17,7 @@ Yii Framework 2 Change Log
...
@@ -17,6 +17,7 @@ Yii Framework 2 Change Log
-
Enh: Added
`favicon.ico`
and
`robots.txt`
to defauly application templates (samdark)
-
Enh: Added
`favicon.ico`
and
`robots.txt`
to defauly application templates (samdark)
-
Enh: Added
`Widget::autoIdPrefix`
to support prefixing automatically generated widget IDs (qiangxue)
-
Enh: Added
`Widget::autoIdPrefix`
to support prefixing automatically generated widget IDs (qiangxue)
-
Enh: Support for file aliases in console command 'message' (omnilight)
-
Enh: Support for file aliases in console command 'message' (omnilight)
-
Chg: Renamed yii
\j
ui
\W
idget::clientEventsMap to clientEventMap (qiangxue)
-
New #1438:
[
MongoDB integration
](
https://github.com/yiisoft/yii2-mongodb
)
ActiveRecord and Query (klimov-paul)
-
New #1438:
[
MongoDB integration
](
https://github.com/yiisoft/yii2-mongodb
)
ActiveRecord and Query (klimov-paul)
2.
0.0 alpha, December 1, 2013
2.
0.0 alpha, December 1, 2013
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment