added experimental global titles to dialogs...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2016-05-14 19:12:54 +03:00
parent adc3d1330b
commit c35be742e6
4 changed files with 40 additions and 5 deletions

View File

@ -37,7 +37,7 @@
max-width: 80vw;
max-height: 90vh;
overflow: hidden;
/*overflow: hidden;*/
transform: translateY(-50%) translateX(-50%);
@ -47,6 +47,24 @@
box-shadow: rgba(0, 0, 0, 0.05) 0.1em 0.1em 3em;
}
/* title */
.content>*:before {
position: absolute;
content: attr(title);
bottom: 100%;
color: silver;
font-weight: 900;
font-style: italic;
font-size: x-large;
line-height: 85%;
opacity: 0.5;
}
/* NOTE: this does not include text...
...need a way to go around this...
*/

View File

@ -488,6 +488,9 @@ var URLHistoryUIActions = actions.Actions({
&& parent.focus()
})
o.dom
.attr('title', 'Location history...')
return o
})],
})

View File

@ -78,6 +78,7 @@ var SlideshowActions = actions.Actions({
// reset the timer if it was not suspended outside...
suspended_timer || that.resetSlideshowTimer()
})
return o
})],
// XXX BUG: there are still problems with focus...
@ -85,7 +86,7 @@ var SlideshowActions = actions.Actions({
// click on the first option with a mouse...
// result:
// the top dialog is not focused...
slideshowDialog: ['Slideshow/Slideshow settings and start...',
slideshowDialog: ['Slideshow/Slideshow...',
widgets.makeUIDialog(function(){
var that = this
@ -154,7 +155,8 @@ var SlideshowActions = actions.Actions({
suspended_timer || that.resetSlideshowTimer()
})
o.dom.addClass('metadata-view tail-action')
o.dom
.addClass('metadata-view tail-action')
return o
})],

View File

@ -553,6 +553,18 @@ module.Dialogs = core.ImageGridFeatures.Feature({
],
actions: DialogsActions,
handlers: [
['__call__',
function(res, action){
if(res instanceof jQuery || (res instanceof widget.Widget)){
var elem = (res.dom || res)
!elem.attr('title') && elem.attr('title',
(this.getDoc(action)[action].shift() || action).split(/[\\\/]/g).pop())
}
}],
],
})
@ -616,7 +628,7 @@ var BrowseActionsActions = actions.Actions({
// base order/priorities...
//
// XXX can we do a deep search -- find any nested action???
browseActions: ['Interface/Browse actions...',
browseActions: ['Interface/Actions...',
makeUIDialog(function(path){
var actions = this
var priority = /^(-?[0-9]+):/
@ -965,7 +977,7 @@ var WidgetTestActions = actions.Actions({
background: 'white',
focusable: true,
})],
testBrowse: ['Test/-99: Demo new style dialog...',
testBrowse: ['Test/-99: Demo new style dialog...',
makeUIDialog(function(){
var actions = this