Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
NyxUI.jl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
Nyx
NyxUI.jl
Commits
969bbbcc
Commit
969bbbcc
authored
5 months ago
by
François LAURENT
Browse files
Options
Downloads
Patches
Plain Diff
fix: prevent resizing during length editing
parent
de7e91f2
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!2
UX improvements
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/apps/muscles/app.jl
+17
-11
17 additions, 11 deletions
src/apps/muscles/app.jl
with
17 additions
and
11 deletions
src/apps/muscles/app.jl
+
17
−
11
View file @
969bbbcc
...
@@ -34,7 +34,6 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
...
@@ -34,7 +34,6 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
@out
export_sequence_link
=
""
@out
export_sequence_link
=
""
@in
export_sequence_click
=
false
@in
export_sequence_click
=
false
#@in delete_sequence_click = false
@in
colormap
=
default_colormap
@in
colormap
=
default_colormap
@out
first_time_in_editmode
=
true
# and in the heatmap view
@out
first_time_in_editmode
=
true
# and in the heatmap view
...
@@ -77,6 +76,7 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
...
@@ -77,6 +76,7 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
series_length
=
length
(
seq
.
times
)
series_length
=
length
(
seq
.
times
)
time_interval
=
step
(
seq
.
times
)
time_interval
=
step
(
seq
.
times
)
start_time
=
first
(
seq
.
times
)
start_time
=
first
(
seq
.
times
)
no_sequences_yet
=
isempty
(
sequence_names
)
end
end
on
(
MuscleWidgets
.
clipboard
(
model
))
do
_
on
(
MuscleWidgets
.
clipboard
(
model
))
do
_
new_clipboard_item
[
!
]
=
false
new_clipboard_item
[
!
]
=
false
...
@@ -108,24 +108,29 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
...
@@ -108,24 +108,29 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
end
end
valid
=
false
valid
=
false
end
end
previous_length
=
length
(
seq
.
times
)
new_length
=
round
(
Int
,
series_length
)
if
series_length
<
1
if
series_length
<
1
@notify
"Time series length must be strictly positive"
:
error
@notify
"Time series length must be strictly positive"
:
error
series_length
=
length
(
seq
.
times
)
series_length
=
previous_length
valid
=
false
valid
=
false
elseif
round
(
series_length
)
!=
series
_length
elseif
series_length
!=
new
_length
@notify
"Time series length must be an integer"
:
error
@notify
"Time series length must be an integer"
:
error
series_length
=
round
(
series
_length
)
series_length
=
new
_length
valid
=
false
valid
=
false
elseif
!
isnothing
(
maxlength
)
&&
maxlength
<
series
_length
elseif
!
isnothing
(
maxlength
)
&&
maxlength
<
new
_length
@notify
"Time series is too long"
:
error
@notify
"Time series is too long"
:
error
series_length
=
length
(
seq
.
times
)
series_length
=
previous_length
valid
=
false
elseif
new_length
<
previous_length
&&
startswith
(
string
(
previous_length
),
string
(
new_length
))
@debug
"Ignoring new size at the moment"
valid
=
false
valid
=
false
end
end
#
#
if
valid
&&
!
(
start_time
==
seq
.
times
[
1
]
&&
time_interval
==
step
(
seq
.
times
)
&&
if
valid
&&
!
(
start_time
==
seq
.
times
[
1
]
&&
time_interval
==
step
(
seq
.
times
)
&&
series_length
==
length
(
seq
.
times
))
new_length
==
previous_length
)
n
=
round
(
Int
,
series_length
)
stop_time
=
start_time
+
(
new_length
-
1
)
*
time_interval
stop_time
=
start_time
+
(
n
-
1
)
*
time_interval
ts
=
start_time
:
time_interval
:
stop_time
ts
=
start_time
:
time_interval
:
stop_time
@info
"Resampling"
start_time
time_interval
series_length
@info
"Resampling"
start_time
time_interval
series_length
MuscleActivities
.
resample!
(
seq
,
ts
)
MuscleActivities
.
resample!
(
seq
,
ts
)
...
@@ -276,15 +281,16 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
...
@@ -276,15 +281,16 @@ const bonito_app = NamedApp(:inherit, Backbone.app)
if
!
(
sequence
.
program_name
in
sequence_names
)
if
!
(
sequence
.
program_name
in
sequence_names
)
push!
(
sequence_names
,
sequence
.
program_name
)
push!
(
sequence_names
,
sequence
.
program_name
)
end
end
notify
(
sequence_names
)
selected_sequence_name
=
sequence
.
program_name
selected_sequence_name
=
sequence
.
program_name
# enable the download and delete buttons
no_sequences_yet
=
false
catch
exception
catch
exception
@error
"Failed to load file"
exception
@error
"Failed to load file"
exception
@notify
"Failed to load file"
:
error
@notify
"Failed to load file"
:
error
end
end
# reset
# reset
fileuploads
=
empty!
(
fileuploads
)
fileuploads
=
empty!
(
fileuploads
)
# enable the download and delete buttons
no_sequences_yet
=
false
end
end
end
end
...
...
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