Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mui
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
mui
Commits
3897711e
Commit
3897711e
authored
Nov 16, 2014
by
hbcui1984
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
可拖动式左滑菜单支持ios平台原生的右滑关闭窗口
parent
68e6ca91
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
3 deletions
+22
-3
examples/hello-mui/examples/offcanvas-drag-left.html
examples/hello-mui/examples/offcanvas-drag-left.html
+18
-0
examples/hello-mui/examples/offcanvas-drag-right.html
examples/hello-mui/examples/offcanvas-drag-right.html
+0
-0
examples/hello-mui/list.html
examples/hello-mui/list.html
+4
-3
No files found.
examples/hello-mui/examples/offcanvas-
with-righ
t.html
→
examples/hello-mui/examples/offcanvas-
drag-lef
t.html
View file @
3897711e
...
@@ -265,6 +265,24 @@
...
@@ -265,6 +265,24 @@
//offCanvas.offCanvas('toggle')//toggle or hide;
//offCanvas.offCanvas('toggle')//toggle or hide;
offCanvas
.
offCanvas
(
'
hide
'
);
offCanvas
.
offCanvas
(
'
hide
'
);
});
});
//实现ios平台的侧滑关闭页面;
if
(
mui
.
os
.
ios
){
var
classList
=
offCanvasContainer
.
classList
;
offCanvasContainer
.
addEventListener
(
'
webkitTransitionEnd
'
,
function
(
e
)
{
if
(
e
.
target
&&
e
.
target
.
classList
.
contains
(
'
mui-inner-wrap
'
))
{
if
(
classList
.
contains
(
'
mui-right
'
)
||
classList
.
contains
(
'
mui-left
'
))
{
//显示状态
mui
.
currentWebview
.
setStyle
({
'
popGesture
'
:
'
none
'
});
}
else
{
mui
.
currentWebview
.
setStyle
({
'
popGesture
'
:
'
close
'
});
}
}
});
}
</script>
</script>
</body>
</body>
...
...
examples/hello-mui/examples/offcanvas-
with-lef
t.html
→
examples/hello-mui/examples/offcanvas-
drag-righ
t.html
View file @
3897711e
File moved
examples/hello-mui/list.html
View file @
3897711e
...
@@ -279,12 +279,12 @@
...
@@ -279,12 +279,12 @@
</a>
</a>
</li>
</li>
<li
class=
"mui-table-view-cell ios-only"
>
<li
class=
"mui-table-view-cell ios-only"
>
<a
class=
"mui-navigate-right"
open-type=
"common"
href=
"examples/offcanvas-
with-lef
t.html"
>
<a
class=
"mui-navigate-right"
open-type=
"common"
href=
"examples/offcanvas-
drag-righ
t.html"
>
可拖动式右滑菜单
可拖动式右滑菜单
</a>
</a>
</li>
</li>
<li
class=
"mui-table-view-cell ios-only"
>
<li
class=
"mui-table-view-cell ios-only"
>
<a
class=
"mui-navigate-right"
open-type=
"common"
href=
"examples/offcanvas-
with-righ
t.html"
>
<a
class=
"mui-navigate-right"
open-type=
"common"
href=
"examples/offcanvas-
drag-lef
t.html"
>
可拖动式左滑菜单
可拖动式左滑菜单
</a>
</a>
</li>
</li>
...
@@ -538,12 +538,13 @@
...
@@ -538,12 +538,13 @@
var
type
=
this
.
getAttribute
(
"
open-type
"
);
var
type
=
this
.
getAttribute
(
"
open-type
"
);
if
(
type
==
"
common
"
){
if
(
type
==
"
common
"
){
if
(
~
id
.
indexOf
(
'
offcanvas-
'
))
{
if
(
~
id
.
indexOf
(
'
offcanvas-
'
))
{
var
pop
=
~
id
.
indexOf
(
'
offcanvas-with-right
'
)?
"
close
"
:
"
none
"
;
mui
.
openWindow
({
mui
.
openWindow
({
id
:
id
,
id
:
id
,
url
:
this
.
href
,
url
:
this
.
href
,
styles
:
{
styles
:
{
zindex
:
9999
,
zindex
:
9999
,
popGesture
:
"
none
"
popGesture
:
pop
},
},
waiting
:{
waiting
:{
autoShow
:
false
autoShow
:
false
...
...
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