Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
unity_webapp
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
unity_webapp
Commits
9bc89f24
Commit
9bc89f24
authored
12 years ago
by
Sebastian Paul
Browse files
Options
Downloads
Patches
Plain Diff
pareview fixes
parent
9b315bcb
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
unity_api.js
+3
-4
3 additions, 4 deletions
unity_api.js
unity_api.module
+8
-9
8 additions, 9 deletions
unity_api.module
unity_hud_menu/unity_hud_menu.module
+8
-9
8 additions, 9 deletions
unity_hud_menu/unity_hud_menu.module
with
19 additions
and
22 deletions
unity_api.js
+
3
−
4
View file @
9bc89f24
...
...
@@ -4,17 +4,16 @@ unityApiFuncGenerator = function (akey) {
}
};
function
unityReady
()
{
//var Unity = external.getUnityObject(1.0);
for
(
key
=
0
;
key
<
Drupal
.
settings
.
unity_api
.
links
.
length
;
key
++
)
{
var
self
=
this
;
var
yourloc
=
"
/
"
+
Drupal
.
settings
.
unity_api
.
links
[
key
].
href
;
var
yourloc
=
"
/
"
+
Drupal
.
settings
.
unity_api
.
links
[
key
].
href
;
Unity
.
addAction
(
"
/
"
+
Drupal
.
settings
.
unity_api
.
links
[
key
].
name
,
unityApiFuncGenerator
(
key
));
}
}
jQuery
(
window
).
load
(
function
(){
window
.
setTimeout
(
function
()
{
var
Unity
=
external
.
getUnityObject
(
1.0
);
window
.
setTimeout
(
function
(){
var
Unity
=
external
.
getUnityObject
(
1.0
);
Unity
.
init
({
name
:
Drupal
.
settings
.
unity_api
.
sitename
,
iconUrl
:
Drupal
.
settings
.
unity_api
.
favicon
,
...
...
This diff is collapsed.
Click to expand it.
unity_api.module
+
8
−
9
View file @
9bc89f24
<?php
/*
* @file Unity Api Integration module.
/**
* @file
* Unity Api Integration module.
*/
/*
*
c
all hooks to build the links.
* @return
/*
*
*
C
all hooks to build the links.
* @return
$linkarray
* array with links from called hooks
*/
function
unity_api_generate_links_array
()
{
...
...
@@ -14,7 +15,7 @@ function unity_api_generate_links_array() {
return
(
$links
);
}
/*
/*
*
* Insert Javascript into the page.
*/
function
unity_api_page_alter
(
&
$page
)
{
...
...
@@ -23,14 +24,12 @@ function unity_api_page_alter(&$page) {
dsm
(
drupal_get_title
());
$faviconurl
=
file_create_url
(
theme_get_setting
(
'favicon_path'
,
variable_get
(
'theme_default'
)));
$my_settings
=
array
(
//'sitename' => variable_get('site_name'),
'sitename'
=>
drupal_get_title
(),
'links'
=>
unity_api_generate_links_array
(),
'favicon'
=>
$faviconurl
,
'baseurl'
=>
"dev.d7"
,
);
//TODO: drupal_alter to allow other modules to alter the output.
// TODO: drupal_alter to allow other modules to alter the output.
drupal_add_js
(
array
(
'unity_api'
=>
$my_settings
),
'setting'
);
}
This diff is collapsed.
Click to expand it.
unity_hud_menu/unity_hud_menu.module
+
8
−
9
View file @
9bc89f24
<?php
/*@file
* submodule which generates links for unity_hud from menu_tree_all_data
/**
* @file
* Submodule which generates links for unity_hud from menu_tree_all_data
*/
/*
/*
*
* Walk through menu_tree and find the links.
*
* @return
* @return $linkarray
* array with links
*/
function
unity_hud_menu_walk
(
$object
)
{
...
...
@@ -24,10 +24,9 @@ function unity_hud_menu_walk($object) {
return
$links
;
}
/*
* implementation of hook_unityapi_addlinks
*
* @return
/**
* Implements hook_unityapi_addlinks().
* @return $linkarray
* array with links
*/
function
unity_hud_menu_unityapi_addlinks
()
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment