Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
renderjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Cédric Le Ninivin
renderjs
Commits
59781d1c
Commit
59781d1c
authored
Apr 19, 2013
by
Ivan Tyagov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Typos.
parent
7e8c50e6
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
renderjs.js
renderjs.js
+5
-4
No files found.
renderjs.js
View file @
59781d1c
// SafeJS add ons
function
makeid
()
{
var
text
=
""
;
var
possible
=
"
ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789
"
;
...
...
@@ -10,6 +12,7 @@ function makeid() {
// when handling the response from the global environment back to the sandbox
var
callbackRegistry
=
{};
// a global variable that holds current gadget, this is bad as it's shared
var
selfGadget
=
{};
...
...
@@ -21,7 +24,6 @@ function registerCallback(callback, id) {
var
communicate
=
function
(
id
,
selector
,
callback
)
{
var
callId
=
makeid
();
registerCallback
(
callback
,
callId
);
postMessage
({
command
:
'
masterAndCommander
'
,
data
:
{
...
...
@@ -62,7 +64,6 @@ function selectorProxy(selector, id) {
};
// Async get gadget by id. out of renderjs for now. needs refactorings
function
asyncGetGadgetById
(
id
,
callback
)
{
var
callId
=
makeid
();
registerCallback
(
callback
,
callId
);
...
...
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