Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Y
yafits
Manage
Activity
Members
Plan
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
artemix
yafits
Commits
ef8ae163
Commit
ef8ae163
authored
1 year ago
by
Moreau Nicolas
Browse files
Options
Downloads
Patches
Plain Diff
Fixes problem with samp in 1D
parent
fc1d55f1
Branches
Branches containing commit
Tags
v23.12.1-dev
Tags containing commit
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
yafitsv/public/javascript/modules/samp_utils.js
+18
-3
18 additions, 3 deletions
yafitsv/public/javascript/modules/samp_utils.js
yafitsv/public/javascript/olqv1d.js
+4
-0
4 additions, 0 deletions
yafitsv/public/javascript/olqv1d.js
yafitsv/views/olqv2d.ejs
+1
-1
1 addition, 1 deletion
yafitsv/views/olqv2d.ejs
with
23 additions
and
4 deletions
yafitsv/public/javascript/modules/samp_utils.js
+
18
−
3
View file @
ef8ae163
...
...
@@ -112,6 +112,7 @@ var SAMPPublisher = function(connector, dataPaths) {
var
sAMPPublisher
=
undefined
;
var
setOnHubAvailability
=
undefined
;
var
setOnHubAvailabilityButtons1D
=
undefined
;
var
setOnHubAvailability2D
=
undefined
;
var
setOnHubAvailabilityButtons
=
undefined
;
var
setOnHubAvailabilityButtonsFirstExec
=
true
;
...
...
@@ -179,7 +180,7 @@ if (withSAMP) {
/**
* Enable or disable SAMP in 2D slice
*/
setOnHubAvailability2D
=
function
(
customControls
,
publishSAMP
)
{
/*
setOnHubAvailability2D = function(customControls,publishSAMP) {
samp_registration_area2D.append(connector.createRegButtons());
let configureSampEnabled = function(isHubRunning) {
//if the hub is not running or the registration into the hub is not done yet,
...
...
@@ -195,7 +196,7 @@ if (withSAMP) {
}
};
connector.onHubAvailability(configureSampEnabled, 3000);
};
};
*/
/**
* Enable or disable SAMP in 3D slice
...
...
@@ -223,6 +224,19 @@ if (withSAMP) {
};
connector
.
onHubAvailability
(
configureSampEnabled
,
3000
);
};
setOnHubAvailabilityButtons1D
=
function
(
samp_registration_area
)
{
if
(
setOnHubAvailabilityButtonsFirstExec
){
samp_registration_area
.
append
(
connector
.
createRegButtons
());
setOnHubAvailabilityButtonsFirstExec
=
false
;
}
//connector.onHubAvailability(configureSampEnabled, 3000);
};
/**
* Enable or disable SAMP from a list of viewers
* @param {*} viewers
...
...
@@ -270,6 +284,7 @@ if (withSAMP) {
export
{
sAMPPublisher
,
setOnHubAvailability
,
setOnHubAvailability2D
,
//setOnHubAvailability2D,
setOnHubAvailabilityButtons1D
,
setOnHubAvailabilityButtons
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
yafitsv/public/javascript/olqv1d.js
+
4
−
0
View file @
ef8ae163
...
...
@@ -11,6 +11,7 @@ import { SpectroApi } from "./modules/serverApi.js";
import
{
Tester
}
from
"
./tests/test1d.js
"
;
import
{
setNedUiListeners
,
setSpectroUiListeners
,
initSpectroUI
,
initSamp
,
initCubeSmoothing
}
from
"
./modules/listeners.js
"
;
import
{
setOnHubAvailabilityButtons1D
}
from
"
./modules/samp_utils.js
"
;
// get user input from spectroscopy form
...
...
@@ -171,6 +172,9 @@ $(document).ready(function() {
// Shows SAMP connector logo if SAMP is activated
initSamp
(
withSAMP
);
if
(
withSAMP
){
setOnHubAvailabilityButtons1D
(
DOMAccessor
.
get3DSampConnection
());
}
$
(
"
#toggle-options
"
).
on
(
"
click
"
,
function
(
event
)
{
...
...
This diff is collapsed.
Click to expand it.
yafitsv/views/olqv2d.ejs
+
1
−
1
View file @
ef8ae163
...
...
@@ -79,7 +79,7 @@
</div>
<div
id=
"fullscreen sidepanel"
>
<div
class=
"container
yafits-container
"
>
<div
class=
"container"
>
<nav
class=
"navbar navbar-dark bg-dark"
>
<button
class=
"navbar-toggler"
type=
"button"
data-toggle=
"collapse"
data-target=
"#navbar-toggle-external-content"
aria-controls=
"navbar-toggle-external-content"
...
...
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