Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gyuricska Milán
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
53aac5bd
authored
Feb 10, 2013
by
Dányi Bence
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
webui: prevent default actions / event propagation for dummy links
parent
96912033
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
one/static/cloud.js
+6
-4
No files found.
one/static/cloud.js
View file @
53aac5bd
...
@@ -527,7 +527,8 @@ $(function() {
...
@@ -527,7 +527,8 @@ $(function() {
/**
/**
* Downloads the specified file (or folder zipped)
* Downloads the specified file (or folder zipped)
*/
*/
self
.
download
=
function
(
item
)
{
self
.
download
=
function
(
item
,
ev
)
{
ev
.
stopPropagation
();
ev
.
preventDefault
();
if
(
window
.
navigator
.
userAgent
.
indexOf
(
'cloud-gui'
)
>
-
1
)
{
if
(
window
.
navigator
.
userAgent
.
indexOf
(
'cloud-gui'
)
>
-
1
)
{
window
.
location
.
href
=
'cloudfile:'
+
self
.
currentPath
()
+
item
.
originalName
;
window
.
location
.
href
=
'cloudfile:'
+
self
.
currentPath
()
+
item
.
originalName
;
return
;
return
;
...
@@ -546,7 +547,8 @@ $(function() {
...
@@ -546,7 +547,8 @@ $(function() {
/**
/**
* Deletes the specified file (or folder)
* Deletes the specified file (or folder)
*/
*/
self
.
delete
=
function
(
item
)
{
self
.
delete
=
function
(
item
,
ev
)
{
ev
.
stopPropagation
();
ev
.
preventDefault
();
$
(
'#modal'
).
show
();
$
(
'#modal'
).
show
();
s
=
""
;
s
=
""
;
if
(
item
.
type
==
gettext
(
'file'
))
{
if
(
item
.
type
==
gettext
(
'file'
))
{
...
@@ -577,10 +579,10 @@ $(function() {
...
@@ -577,10 +579,10 @@ $(function() {
* Renames the specified file
* Renames the specified file
*/
*/
self
.
rename
=
function
(
item
,
e
)
{
self
.
rename
=
function
(
item
,
e
)
{
e
.
stopPropagation
();
e
.
stopPropagation
();
e
.
preventDefault
();
var
oldName
=
$
(
e
.
target
).
parent
().
parent
().
parent
().
find
(
'.name'
).
html
();
var
oldName
=
$
(
e
.
target
).
parent
().
parent
().
parent
().
find
(
'.name'
).
html
();
$
(
e
.
target
).
parent
().
unbind
(
'click'
).
click
(
function
(
f
)
{
$
(
e
.
target
).
parent
().
unbind
(
'click'
).
click
(
function
(
f
)
{
f
.
stopPropagation
();
f
.
stopPropagation
();
f
.
preventDefault
();
$
(
e
.
target
).
parent
().
parent
().
parent
().
find
(
'.name'
).
html
(
oldName
);
$
(
e
.
target
).
parent
().
parent
().
parent
().
find
(
'.name'
).
html
(
oldName
);
$
(
e
.
target
).
parent
().
click
(
function
(
g
)
{
$
(
e
.
target
).
parent
().
click
(
function
(
g
)
{
g
.
stopPropagation
();
g
.
stopPropagation
();
...
...
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