diff --git a/app/config.json b/app/config.json index d5a6d449..6973865f 100644 --- a/app/config.json +++ b/app/config.json @@ -3,6 +3,10 @@ "sessionPath": "/home/bordun/oscwork/oschtmlgui/sessions/", "recentSessions": [ "/home/bordun/oscwork/oschtmlgui/sessions/demo.js", - "/home/bordun/oscwork/oschtmlgui/sessions/demo-full.js" + "/home/bordun/oscwork/oschtmlgui/sessions/xy.js", + "/home/bordun/oscwork/oschtmlgui/sessions/demo-full.js", + "/home/bordun/oscwork/oschtmlgui/sessions/fadertest.js", + "/home/bordun/oscwork/oschtmlgui/sessions/monitorsjeannot.js", + "/home/bordun/oscwork/oschtmlgui/sessions/sebkhachott.js" ] } \ No newline at end of file diff --git a/browser/css/jquery.nouislider.scss b/browser/css/jquery.nouislider.scss deleted file mode 100644 index c3494a22..00000000 --- a/browser/css/jquery.nouislider.scss +++ /dev/null @@ -1,296 +0,0 @@ - -/* Functional styling; - * These styles are required for noUiSlider to function. - * You don't need to change these rules to apply your design. - */ -.noUi-target, -.noUi-target * { --webkit-touch-callout: none; --webkit-user-select: none; --ms-touch-action: none; --ms-user-select: none; --moz-user-select: none; --moz-box-sizing: border-box; - box-sizing: border-box; -} -.noUi-target { - position: relative; -} -.noUi-base { - width: 100%; - height: 100%; - position: relative; -} -.noUi-origin { - position: absolute; - right: 0; - top: 0; - left: 0; - bottom: 0; -} -.noUi-handle { - position: relative; - z-index: 1; -} -.noUi-stacking .noUi-handle { -/* This class is applied to the lower origin when - its values is > 50%. */ - z-index: 10; -} -.noUi-stacking + .noUi-origin { -/* Fix stacking order in IE7, which incorrectly - creates a new context for the origins. */ - *z-index: -1; -} -.noUi-state-tap .noUi-origin { --webkit-transition: left 0.3s, top 0.3s; - transition: left 0.3s, top 0.3s; -} -.noUi-state-drag * { - cursor: inherit !important; -} - -/* Painting and performance; - * Browsers can paint handles in their own layer. - */ -.noUi-base { - -webkit-transform: translate3d(0,0,0); - transform: translate3d(0,0,0); -} - -/* Slider size and handle placement; - */ -.noUi-horizontal { - height: 4px!important; -} -.noUi-handle { - border-radius:100%!important; - background:$color-accent!important; - box-shadow:0 0 10px 0px #aaa inset,0 0 1px 1px rgba(0,0,0,.5),0 0 0 3px rgba(255,255,255,.2)!important -} -.noUi-horizontal .noUi-handle { - width: 10px; - height: 10px; - left: -5px; - top: -3px; - border:0; - padding:0; -} -.noUi-vertical { - width: 4px; -} -.noUi-vertical .noUi-handle { - width: 10px; - height: 10px; - left: -3px; - top: -5px; -} - -/* Styling; - */ -.noUi-background { - background: #FAFAFA; -} -.noUi-connect { - background: $color-accent; - -webkit-transition: background 450ms; - transition: background 450ms; -} -.noUi-origin { - border-radius: 2px; -} -.noUi-target { - border-radius: 4px; - border: 1px solid #D3D3D3; - -} -.noUi-target.noUi-connect { - -} - -/* Handles; - */ - -.noUi-handle { - background: #FFF; - box-shadow: inset 0 0 1px #FFF, - inset 0 1px 7px #EBEBEB, - 0 3px 6px -3px #BBB; - cursor: -webkit-grab; - &:active { - cursor: -webkit-grabbing; - } -} -.noUi-active { - box-shadow: inset 0 0 1px #FFF, - inset 0 1px 7px #DDD, - 0 3px 6px -3px #BBB; -} - - - -/* Disabled state; - */ -[disabled].noUi-connect, -[disabled] .noUi-connect { - background: #B8B8B8; -} -[disabled] .noUi-handle { - cursor: not-allowed; -} - - -/* PIPS */ - - -/* Base; - * - */ -.noUi-pips, -.noUi-pips * { --moz-box-sizing: border-box; - box-sizing: border-box; -} -.noUi-pips { - position: absolute; - font: 400 12px Arial; - color: #999; -} - -/* Values; - * - */ -.noUi-value { - width: 40px; - position: absolute; - text-align: center; -} -.noUi-value-sub { - color: #ccc; - font-size: 10px; -} - -/* Markings; - * - */ -.noUi-marker { - position: absolute; - background: #CCC; -} -.noUi-marker-sub { - background: #AAA; -} -.noUi-marker-large { - background: #AAA; -} - -/* Horizontal layout; - * - */ -.noUi-pips-horizontal { - padding: 10px 0; - height: 50px; - top: 100%; - left: 0; - width: 100%; -} -.noUi-value-horizontal { - margin-left: -20px; - padding-top: 20px; -} -.noUi-value-horizontal.noUi-value-sub { - padding-top: 15px; -} - -.noUi-marker-horizontal.noUi-marker { - margin-left: -1px; - width: 2px; - height: 5px; -} -.noUi-marker-horizontal.noUi-marker-sub { - height: 10px; -} -.noUi-marker-horizontal.noUi-marker-large { - height: 15px; -} - -/* Vertical layout; - * - */ -.noUi-pips-vertical { - padding: 0 10px; - height: 100%; - top: 0; - left: 100%; -} -.noUi-value-vertical { - width: 15px; - margin-left: 20px; - margin-top: -5px; -} - -.noUi-marker-vertical.noUi-marker { - width: 5px; - height: 2px; - margin-top: -1px; -} -.noUi-marker-vertical.noUi-marker-sub { - width: 10px; -} -.noUi-marker-vertical.noUi-marker-large { - width: 15px; -} - - - -.noUi-background { - background:#222; - border:0px; - border-radius:0px; - box-shadow:0 0 0; -} - -.noUi-target { - box-shadow:0 0 0; -} -.noUi-base { - z-index:2; -} -.noUi-handle { - border-radius:0; - box-shadow:0 0 0; - - border-color:rgba(255,255,255,0.4); -} - - -.noUi-connect { - background:$color-accent; - border:0; - border-radius:0; -} - - -.noUi-handle:after { - content:""; - position:absolute; - height:500px; - left:-5000px; - width:10000px; - top:-250px; - background:none; - display:block!important; -} -.noUi-pips { - font-size:11px; - font-family:sans; -} -.noUi-value-vertical { - margin-top:-7px; -} -.noUi-marker-vertical.noUi-marker { - height:1px; -} -.noUi-marker-horizontal.noUi-marker { - width:1px; -} diff --git a/browser/css/style.scss b/browser/css/style.scss index cfa7c8c6..eaacfa35 100644 --- a/browser/css/style.scss +++ b/browser/css/style.scss @@ -444,18 +444,28 @@ a { - -.spinner { +#loading { position: absolute; top:50%; left:50%; - margin:-15px 0 0 -15px; - height:30px; - width:30px; - border-radius: 50%; - border:2px solid rgba(0,0,0,.2); - border-top-color:$color-accent; - animation: spin .5s linear infinite; + margin-top:-15px; + text-align: center; + .spinner { + display: block; + margin: 0 auto; + height:30px; + width:30px; + border-radius: 50%; + border:2px solid rgba(0,0,0,.2); + border-top-color:$color-accent; + animation: spin .5s linear infinite; + } + #status { + margin-top: 10px; + display: inline-block; + + } + } @keyframes spin { @@ -534,51 +544,92 @@ a { position:relative;vertical-align:top; } -/* BUTTON */ -$button-size:20px; -.button-wrapper { - height:100%; +/* BUTTONS */ + + +.toggle { width:95px; - overflow:hidden; - padding: 10px 0 40px; - position: relative; - .button { - width:100%; + height:100%; + padding:10px 1px 0; + cursor: pointer; + div { + display: flex; + align-items: center; + justify-content: center; height:100%; - position:relative; - outline:1px solid $color-bg; - outline-offset: -10px; + text-align: center; + span { + white-space: nowrap; + text-overflow: ellipsis; + } background:$bg-button; - box-shadow: 0 0 0 1px $color-bg inset; - cursor: pointer; - &:after{ - content:""; - position:absolute; - height:$button-size; - width:$button-size; - top:50%;left:50%; - margin:(- $button-size/2) 0 0 (- $button-size/2); - border-radius:$button-size; - background:$color-bg; - } - &.on:after { - background:$color-accent; - box-shadow:0 0 0 4px rgba(255,255,255,0.1); - } + color:$color-text-fade; } - input { - position:absolute; - bottom:0; - box-shadow: 0 0 1px 0 $color-border inset; + &.on div { + background:transparentize($color-accent,.4); + color:$color-text; + } + +} + +.stack .toggle { + float:right; + width:70%; + height:70px; + padding: 0 0 0 10px; + position: static; +} + +.switch { + width:95px; + height:100%; + padding:10px 1px 0; + cursor: pointer; + display: flex; + flex-direction:column; + align-items: stretch; + .value { + background:$bg-button; + color:$color-text-fade; + display: flex; + align-items: center; + justify-content: center; + height:100%; + width:100%; + margin-bottom:2px; + &:last-child { + margin-bottom:0; + } + &.on { + background:transparentize($color-accent,.4); + color:$color-text; + + } } } +.stack .switch { + float:right; + width:70%; + height:70px; + padding: 0 0 0 10px; + position: static; + flex-direction:row; + .value { + margin-bottom:0px; + margin-right:2px; + &:last-child { + margin-right:0; + } + } +} + /* STACK (contains any widgets) */ .stack { -width:400px; + width:400px; height:auto; padding-bottom:0; border-bottom: 0; @@ -611,18 +662,7 @@ width:400px; clear:both; } } -.stack .fader { - width:100%; -} -.stack .fader-wrapper-outer { - padding:0; -} -.stack .fader-wrapper { - padding:20px 20px; - float:right; - width:70%; - height:70px; -} + .stack .button-wrapper { float:right; width:70%; @@ -636,17 +676,14 @@ width:400px; .stack .widget .title { width:30%; height:35px; - //border-right:1px solid $color-border; -} -.stack .fader-wrapper-outer input, .stack .button-wrapper input { - width:30%; - height:35px; - left:0; - right:auto; - border-top:0; - //border-right:1px solid $color-border; } + + + + + + .stack .xy-wrapper { float:right; width:70%; @@ -655,6 +692,14 @@ width:400px; padding-left:10px; } + + + + + + + + /* STRIP (vertical fader) */ .fader-wrapper-outer { @@ -711,8 +756,12 @@ width:400px; overflow: hidden; .handle { position:absolute; - height:0; - width:0; + height:0px; + width:0px; + bottom:0; + left:0; + max-height:100%; + max-width:100%; z-index:2; cursor: -webkit-grab; &:active { @@ -722,13 +771,13 @@ width:400px; content:""; position:absolute; top:-.5px; - left:-1px; + right:-1px; //box-shadow:0 0 10px 0px #aaa inset,0 0 1px 1px rgba(0,0,0,.5),0 0 0 3px rgba(255,255,255,.2)!important; border-radius:100%!important; //background:$color-accent!important; width: 20px; height: 20px; - margin:-10px 0 0 -10px; + margin:-10px -10px 0 0; box-shadow: 0 0 0 1000px rgba(black,.5), 0 0 0 1px rgba(white,.2); } @@ -782,23 +831,32 @@ width:400px; margin-top:10px; background:transparent linear-gradient(to left, #F00, #FF0080, #F0F, #8000FF, #00F, #0080FF, #0FF, #00FF80, #0F0, #80FF00, #FF0, #FF8000, #F00) repeat scroll 0% 0%; overflow: hidden; + position: relative; .handle { position:absolute; height:100%; - width:1px; + max-width: 100%; + width:0; z-index:2; + left:0; + bottom:0; + cursor: -webkit-grab; + &:active { + cursor: -webkit-grabbing; + } &:after { content:""; position:absolute; top:50%; - left:-1px; + right:-1px; box-shadow: 0 0 0 1000px rgba(black,.5), 0 0 0 1px rgba(white,.2); border-radius:100%!important; width: 11px; height: 11px; - margin:-5px 0 0 -4px; + margin:-5px -4px 0 0; } - span { + &:before { + content:""; position:absolute; top:0; left:0; @@ -810,3 +868,132 @@ width:400px; } } + + + +.f-wrapper-outer { + padding-bottom:30px; + overflow:hidden; + height:100%; + width:100%; + position: relative; + input { + position:absolute; + bottom:0; + box-shadow: 0 0 1px 0 $color-border inset; + } +} + +.f-wrapper { + padding:20px 15px 20px 20px ; + overflow:hidden; + height:100%; + width:95px; + position: relative; + + .f { + height:100%; + width:4px; + background:#222; + position: relative; + .handle { + position: absolute; + bottom:0!important; + top:auto!important; + width:100%; + height:0px; + max-height:100%; + max-width:100%; + cursor: -webkit-grab; + background:$color-accent; + z-index: 1; + &:after { //.ui-resizable-handle { + content:""; + position: absolute; + height:2000px; + width:2000px; + margin:-1000px 0 0 -1000px; + + } + } + } + .pips { + position: absolute; + top:-1%; + bottom:1%; + left:14px; + } + .pip { + height:1%; + width:4px; + border-bottom:1px solid $color-text; + &.val { + width:10px; + position: relative; + span { + position: relative; + width:30px; + display: block; + text-align: center; + font-size:11px; + line-height: 12px; + left:15px; + top:-2px; + color:#ccc; + } + } + } +} + + +.stack .f-wrapper-outer { + input { + width:30%; + height:35px; + left:0; + right:auto; + border-top:0; + top:35px; + } + .f { + width:100%; + height:4px; + .handle { + height:100%!important; + width:0; + } + } + .f-wrapper-outer { + padding:0; + } + .f-wrapper { + padding:20px 20px; + float:right; + width:70%; + height:70px; + } + .pips { + top:14px;left:0; + right:0; + display: flex; + flex-direction:row; + align-items: stretch; + } + .pip { + width:100%; + display: block; + height:4px; + border-bottom:0; + border-right:1px solid $color-text; + &.val { + width:1%; + float:left; + height:10px; + span { + top:15px; + left:-15px; + } + } + } + +} diff --git a/browser/js/app/callbacks.js b/browser/js/app/callbacks.js index a1af1bda..805040b7 100644 --- a/browser/js/app/callbacks.js +++ b/browser/js/app/callbacks.js @@ -34,9 +34,9 @@ ipc.on('openSession',function(data){ require(data) if (TABS!=false) { $('#lobby').hide() - $('#container').append('
') + $('#container').append('
') setTimeout(function(){ - init(function(){$('#container .spinner').hide()}); + init(function(){$('#loading').hide()}); },1) } else { diff --git a/browser/js/app/init.js b/browser/js/app/init.js index 3d43ce0a..6c667790 100644 --- a/browser/js/app/init.js +++ b/browser/js/app/init.js @@ -1,4 +1,5 @@ + init = function(callback) { parsetabs(TABS,false,false) @@ -55,12 +56,13 @@ init = function(callback) { // horizontal scrolling with mousewheel - // if shift is pressed or if mouse is on h-scrollbar + // if shift is pressed (native), or if there is no vertical scrollbar, + // or if mouse is on h-scrollbar $('.tab').on('mousewheel',function(e) { // console.log(e) var h = $('#container').innerHeight()-20-$(this).parents('.tab').length*5; - if (e.shiftKey) { - $(this).scrollLeft($(this).scrollLeft()+e.originalEvent.deltaX); + if ($(this).get(0).scrollHeight+20 == $(this).height()) { + $(this).scrollLeft($(this).scrollLeft()+e.originalEvent.deltaY); e.preventDefault(); } else if (e.pageY>=h) { $(this).scrollLeft($(this).scrollLeft()+e.originalEvent.deltaY); @@ -74,9 +76,9 @@ init = function(callback) { $('#sidepanel').append('\ -
\ + \ \ -
\ + \