mobile-wizard: fix shape glow panel
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com> Change-Id: I5903b0f8fe0b39d7243db59a0627f62644942156
This commit is contained in:
parent
0689ff580a
commit
e5fc1d0bca
2 changed files with 22 additions and 3 deletions
|
@ -1249,6 +1249,9 @@ L.Control.JSDialogBuilder = L.Control.extend({
|
|||
|
||||
case 'fontsizecombobox':
|
||||
return '.uno:FontHeight';
|
||||
|
||||
case 'LB_GLOW_COLOR':
|
||||
return '.uno:GlowColor';
|
||||
}
|
||||
|
||||
return null;
|
||||
|
@ -2564,6 +2567,10 @@ L.Control.JSDialogBuilder = L.Control.extend({
|
|||
_sendColorCommand: function(builder, data, color) {
|
||||
var gradientItem;
|
||||
|
||||
if (data.id === 'LB_GLOW_COLOR') {
|
||||
data.id = 'GlowColor';
|
||||
}
|
||||
|
||||
if (data.id === 'fillgrad1') {
|
||||
gradientItem = builder.map['stateChangeHandler'].getItemValue('.uno:FillGradient');
|
||||
gradientItem.startcolor = color;
|
||||
|
@ -2588,7 +2595,7 @@ L.Control.JSDialogBuilder = L.Control.extend({
|
|||
builder.map.sendUnoCommand('.uno:FillPageGradient?FillPageGradientJSON:string=' + JSON.stringify(gradientItem));
|
||||
return;
|
||||
} else if (data.id === 'Color' || data.id === 'CharBackColor' || data.id === 'FillColor'
|
||||
|| data.id === 'XLineColor') {
|
||||
|| data.id === 'XLineColor' || data.id === 'GlowColor') {
|
||||
var params = {};
|
||||
params[data.id] = {
|
||||
type : 'long',
|
||||
|
|
|
@ -665,9 +665,21 @@ L.Control.MobileWizardBuilder = L.Control.JSDialogBuilder.extend({
|
|||
|
||||
// apply needed modifications for mobile
|
||||
_modifySidebarNodes: function(data) {
|
||||
for (var i in data) {
|
||||
if ((data[i].id === 'fillgrad1' || data[i].id === 'fillgrad2') && data[i].type === 'menubutton')
|
||||
for (var i = data.length - 1; i >= 0; i--) {
|
||||
if (data[i].type === 'menubutton' &&
|
||||
(data[i].id === 'fillgrad1'
|
||||
|| data[i].id === 'fillgrad2'
|
||||
|| data[i].id === 'LB_GLOW_COLOR')) {
|
||||
|
||||
if (data[i].id === 'LB_GLOW_COLOR')
|
||||
data[i].command = '.uno:GlowColor';
|
||||
|
||||
data[i].type = 'colorlistbox';
|
||||
} else if ((data[i].command === 'sidebargradient' && data[i].type === 'toolitem')
|
||||
|| (data[i].id === 'radiusglow' && data[i].type === 'fixedtext')
|
||||
|| (data[i].id === 'radiussoftedge' && data[i].type === 'fixedtext')) {
|
||||
data.splice(i, 1);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in a new issue