This commit is contained in:
j 2011-10-11 20:20:46 +02:00
commit 04acc3c6f3
5 changed files with 54 additions and 9 deletions

View file

@ -16,7 +16,8 @@ pandora.ui.eventsDialog = function() {
{}, {},
Ox.Button({ Ox.Button({
id: 'done', id: 'done',
title: 'Done' title: 'Done',
width: 48
}).bindEvent({ }).bindEvent({
click: function() { click: function() {
that.close(); that.close();

View file

@ -87,6 +87,9 @@ pandora.ui.namesDialog = function() {
.find('.OxItem.OxSelected > .OxCell.OxColumnSortname') .find('.OxItem.OxSelected > .OxCell.OxColumnSortname')
.trigger('mousedown'); .trigger('mousedown');
}, },
select: function(data) {
$findButton.options({disabled: !data.ids.length});
},
submit: function(data) { submit: function(data) {
Ox.Request.clearCache('findNames'); Ox.Request.clearCache('findNames');
pandora.api.editName({ pandora.api.editName({
@ -96,10 +99,27 @@ pandora.ui.namesDialog = function() {
} }
}), }),
$findButton = Ox.Button({
disabled: true,
title: 'Find',
width: 48,
}).bindEvent({
click: function() {
that.close();
pandora.UI.set('find', {
conditions: [{
key: 'name',
value: $list.value($list.options('selected'), 'name'),
operator: '='
}],
operator: '&'
})
}
}),
that = Ox.Dialog({ that = Ox.Dialog({
buttons: [ buttons: [
Ox.Button({ Ox.Button({
id: 'manageTitles',
title: 'Manage Titles...' title: 'Manage Titles...'
}).bindEvent({ }).bindEvent({
click: function() { click: function() {
@ -107,9 +127,10 @@ pandora.ui.namesDialog = function() {
} }
}), }),
{}, {},
$findButton,
Ox.Button({ Ox.Button({
id: 'done', title: 'Done',
title: 'Done' width: 48
}).bindEvent({ }).bindEvent({
click: function() { click: function() {
that.close(); that.close();

View file

@ -44,7 +44,8 @@ pandora.ui.placesDialog = function() {
{}, {},
Ox.Button({ Ox.Button({
id: 'done', id: 'done',
title: 'Done' title: 'Done',
width: 48
}).bindEvent({ }).bindEvent({
click: function() { click: function() {
that.close(); that.close();

View file

@ -76,6 +76,9 @@ pandora.ui.titlesDialog = function() {
.find('.OxItem.OxSelected > .OxCell.OxColumnSorttitle') .find('.OxItem.OxSelected > .OxCell.OxColumnSorttitle')
.trigger('mousedown'); .trigger('mousedown');
}, },
select: function(data) {
$findButton.options({disabled: !data.ids.length});
},
submit: function(data) { submit: function(data) {
Ox.Request.clearCache('findTitles'); Ox.Request.clearCache('findTitles');
pandora.api.editTitle({ pandora.api.editTitle({
@ -85,10 +88,27 @@ pandora.ui.titlesDialog = function() {
} }
}), }),
$findButton = Ox.Button({
disabled: true,
title: 'Find',
width: 48,
}).bindEvent({
click: function() {
that.close();
pandora.UI.set('find', {
conditions: [{
key: 'title',
value: $list.value($list.options('selected'), 'title'),
operator: '='
}],
operator: '&'
})
}
}),
that = Ox.Dialog({ that = Ox.Dialog({
buttons: [ buttons: [
Ox.Button({ Ox.Button({
id: 'manageNames',
title: 'Manage Names...' title: 'Manage Names...'
}).bindEvent({ }).bindEvent({
click: function() { click: function() {
@ -96,9 +116,10 @@ pandora.ui.titlesDialog = function() {
} }
}), }),
{}, {},
$findButton,
Ox.Button({ Ox.Button({
id: 'done', title: 'Done',
title: 'Done' width: 48
}).bindEvent({ }).bindEvent({
click: function() { click: function() {
that.close(); that.close();

View file

@ -292,7 +292,8 @@ pandora.ui.usersDialog = function() {
}), }),
Ox.Button({ Ox.Button({
id: 'done', id: 'done',
title: 'Done' title: 'Done',
width: 48
}).bindEvent({ }).bindEvent({
click: function() { click: function() {
that.close(); that.close();