[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - 2 commits - comphelper/source desktop/source include/comphelper sc/source sc/uiconfig sc/UIConfig_scalc.mk solenv/sanitizers
merttumer (via logerrit)
logerrit at kemper.freedesktop.org
Tue Sep 3 19:43:21 UTC 2019
comphelper/source/misc/lok.cxx | 12
desktop/source/lib/init.cxx | 12
include/comphelper/lok.hxx | 6
sc/UIConfig_scalc.mk | 2
sc/source/ui/condformat/condformatdlg.cxx | 3
sc/source/ui/condformat/condformatdlgentry.cxx | 3
sc/uiconfig/scalc/ui/conditionalentrymobile.ui | 455 ++++++++++++++++++
sc/uiconfig/scalc/ui/conditionalformatdialogmobile.ui | 300 +++++++++++
solenv/sanitizers/ui/modules/scalc.suppr | 20
9 files changed, 811 insertions(+), 2 deletions(-)
New commits:
commit 6d2e25ce53b561f0b5a250f0a1b7e96811b00e17
Author: merttumer <mert.tumer at collabora.com>
AuthorDate: Tue Jul 30 15:30:06 2019 +0300
Commit: Andras Timar <andras.timar at collabora.com>
CommitDate: Tue Sep 3 21:42:42 2019 +0200
Added mobile friendly ui design for ConditionalFormattingDialog
[ Miklos: added solenv/ bits to silence the same warnings as the
non-mobile layout. ]
(cherry picked from commit d2b4b608696e7a6ba7ed15c97972aa8ed3707bb2)
Conflicts:
sc/source/ui/condformat/condformatdlg.cxx
sc/source/ui/condformat/condformatdlgentry.cxx
solenv/sanitizers/ui/modules/scalc.suppr
Change-Id: If2d91da45cf5eecf099f246320ffaf84f55708f1
Reviewed-on: https://gerrit.libreoffice.org/78307
Reviewed-by: Andras Timar <andras.timar at collabora.com>
Tested-by: Andras Timar <andras.timar at collabora.com>
diff --git a/sc/UIConfig_scalc.mk b/sc/UIConfig_scalc.mk
index 8b36d066b932..e91e9c35959b 100644
--- a/sc/UIConfig_scalc.mk
+++ b/sc/UIConfig_scalc.mk
@@ -98,7 +98,9 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/scalc,\
sc/uiconfig/scalc/ui/colwidthdialog \
sc/uiconfig/scalc/ui/condformatmanager \
sc/uiconfig/scalc/ui/conditionalformatdialog \
+ sc/uiconfig/scalc/ui/conditionalformatdialogmobile \
sc/uiconfig/scalc/ui/conditionalentry \
+ sc/uiconfig/scalc/ui/conditionalentrymobile \
sc/uiconfig/scalc/ui/conditionaliconset \
sc/uiconfig/scalc/ui/conflictsdialog \
sc/uiconfig/scalc/ui/consolidatedialog \
diff --git a/sc/source/ui/condformat/condformatdlg.cxx b/sc/source/ui/condformat/condformatdlg.cxx
index 79e0e3f233d6..91ea772d8065 100644
--- a/sc/source/ui/condformat/condformatdlg.cxx
+++ b/sc/source/ui/condformat/condformatdlg.cxx
@@ -7,6 +7,7 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
+#include <comphelper/lok.hxx>
#include <condformatdlg.hxx>
#include <vcl/vclevent.hxx>
@@ -515,7 +516,7 @@ ScCondFormatDlg::ScCondFormatDlg(SfxBindings* pB, SfxChildWindow* pCW,
vcl::Window* pParent, ScViewData* pViewData,
const ScCondFormatDlgItem* pItem)
: ScAnyRefDlg(pB, pCW, pParent, "ConditionalFormatDialog",
- "modules/scalc/ui/conditionalformatdialog.ui")
+ (comphelper::LibreOfficeKit::isMobile()?OUString("modules/scalc/ui/conditionalformatdialogmobile.ui"):OUString("modules/scalc/ui/conditionalformatdialog.ui")))
, mpViewData(pViewData)
, mpLastEdit(nullptr)
, mpDlgItem(static_cast<ScCondFormatDlgItem*>(pItem->Clone()))
diff --git a/sc/source/ui/condformat/condformatdlgentry.cxx b/sc/source/ui/condformat/condformatdlgentry.cxx
index 2483ebe29d7f..4c6682253fa0 100644
--- a/sc/source/ui/condformat/condformatdlgentry.cxx
+++ b/sc/source/ui/condformat/condformatdlgentry.cxx
@@ -33,6 +33,7 @@
#include <tabvwsh.hxx>
#include <simpleformulacalc.hxx>
#include <unotools/charclass.hxx>
+#include <comphelper/lok.hxx>
#include <colorformat.hxx>
#include <scresid.hxx>
@@ -48,7 +49,7 @@ ScCondFrmtEntry::ScCondFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const S
, mpDoc(pDoc)
, maPos(rPos)
{
- m_pUIBuilder.reset(new VclBuilder(this, getUIRootDir(), "modules/scalc/ui/conditionalentry.ui"));
+ m_pUIBuilder.reset(new VclBuilder(this, getUIRootDir(), (comphelper::LibreOfficeKit::isMobile()?OUString("modules/scalc/ui/conditionalentrymobile.ui"):OUString("modules/scalc/ui/conditionalentry.ui"))));
get(maGrid, "grid");
get(maFtCondNr, "number");
diff --git a/sc/uiconfig/scalc/ui/conditionalentrymobile.ui b/sc/uiconfig/scalc/ui/conditionalentrymobile.ui
new file mode 100644
index 000000000000..a4f1b39185bd
--- /dev/null
+++ b/sc/uiconfig/scalc/ui/conditionalentrymobile.ui
@@ -0,0 +1,455 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.22.1 -->
+<interface domain="sc">
+ <requires lib="gtk+" version="3.0"/>
+ <requires lib="LibreOffice" version="1.0"/>
+ <object class="GtkGrid" id="grid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="border_width">6</property>
+ <property name="orientation">vertical</property>
+ <property name="row_spacing">7</property>
+ <child>
+ <object class="GtkGrid" id="grid1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="column_spacing">2</property>
+ <child>
+ <object class="GtkLabel" id="number">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="condition">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid" id="grid2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="resize_mode">immediate</property>
+ <property name="row_spacing">12</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkComboBoxText" id="type">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|type">All Cells</item>
+ <item translatable="yes" context="conditionalentrymobile|type">Cell value is</item>
+ <item translatable="yes" context="conditionalentrymobile|type">Formula is</item>
+ <item translatable="yes" context="conditionalentrymobile|type">Date is</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="height">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="style">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|style">New Style...</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">6</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="options">
+ <property name="label" translatable="yes" context="conditionalentrymobile|options">More Options...</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">12</property>
+ </packing>
+ </child>
+ <child>
+ <object class="svxlo-SvxFontPrevWindow" id="preview:border">
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes" context="conditionalentrymobile|preview|tooltip_text">Example</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">7</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkComboBoxText" id="typeis">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|typeis">equal to</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">less than</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">greater than</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">less than or equal to</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">greater than or equal to</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">not equal to</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">between</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">not between</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">duplicate</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">not duplicate</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">top 10 elements</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">bottom 10 elements</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">top 10 percent</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">bottom 10 percent</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">above average</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">below average</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">above or equal average</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">below or equal average</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">Error</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">No Error</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">Begins with</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">Ends with</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">Contains</item>
+ <item translatable="yes" context="conditionalentrymobile|typeis">Not Contains</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="datetype">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Today</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Yesterday</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Tomorrow</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Last 7 days</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">This week</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Last week</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Next week</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">This month</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Last month</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Next month</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">This year</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Last year</item>
+ <item translatable="yes" context="conditionalentrymobile|datetype">Next year</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="colorformat">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|colorformat">Color Scale (2 Entries)</item>
+ <item translatable="yes" context="conditionalentrymobile|colorformat">Color Scale (3 Entries)</item>
+ <item translatable="yes" context="conditionalentrymobile|colorformat">Data Bar</item>
+ <item translatable="yes" context="conditionalentrymobile|colorformat">Icon Set</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="foruilo-RefEdit" id="formula">
+ <property name="can_focus">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">4</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="column_spacing">12</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="foruilo-RefEdit" id="val1">
+ <property name="can_focus">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="foruilo-RefEdit" id="val2">
+ <property name="can_focus">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="iconsettype">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Arrows</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Gray Arrows</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Flags</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Traffic Lights 1</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Traffic Lights 2</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Signs</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Symbols 1</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Symbols 2</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Smileys</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Stars</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Triangles</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">3 Colored Smileys</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">4 Arrows</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">4 Gray Arrows</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">4 Circles Red to Black</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">4 Ratings</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">4 Traffic Lights</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">5 Arrows</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">5 Gray Arrows</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">5 Ratings</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">5 Quarters</item>
+ <item translatable="yes" context="conditionalentrymobile|iconsettype">5 Boxes</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="styleft">
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes" context="conditionalentrymobile|styleft">Apply Style:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">style</property>
+ <property name="xalign">0</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">5</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkComboBoxText" id="colscalemax">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|colscalemax">Automatic</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemax">Min</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemax">Max</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemax">Percentile</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemax">Value</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemax">Percent</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemax">Formula</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="edcolscalemax">
+ <property name="can_focus">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="svxcorelo-SvxColorListBox" id="lbcolmax">
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">11</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkComboBoxText" id="colscalemiddle">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|colscalemiddle">Automatic</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemiddle">Min</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemiddle">Max</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemiddle">Percentile</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemiddle">Value</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemiddle">Percent</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemiddle">Formula</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="height">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="edcolscalemiddle">
+ <property name="can_focus">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="svxcorelo-SvxColorListBox" id="lbcolmiddle">
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">10</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="valueft">
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes" context="conditionalentrymobile|valueft">Enter a value:</property>
+ <property name="xalign">0</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">8</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkComboBoxText" id="colscalemin">
+ <property name="can_focus">False</property>
+ <items>
+ <item translatable="yes" context="conditionalentrymobile|colscalemin">Automatic</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemin">Min</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemin">Max</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemin">Percentile</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemin">Value</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemin">Percent</item>
+ <item translatable="yes" context="conditionalentrymobile|colscalemin">Formula</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="edcolscalemin">
+ <property name="can_focus">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="svxcorelo-SvxColorListBox" id="lbcolmin">
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">9</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid" id="iconparent">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">12</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/sc/uiconfig/scalc/ui/conditionalformatdialogmobile.ui b/sc/uiconfig/scalc/ui/conditionalformatdialogmobile.ui
new file mode 100644
index 000000000000..ec4c49ca3a4e
--- /dev/null
+++ b/sc/uiconfig/scalc/ui/conditionalformatdialogmobile.ui
@@ -0,0 +1,300 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.22.1 -->
+<interface domain="sc">
+ <requires lib="gtk+" version="3.0"/>
+ <requires lib="LibreOffice" version="1.0"/>
+ <object class="GtkDialog" id="ConditionalFormatDialog">
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes" context="conditionalformatdialogmobile|ConditionalFormatDialog">Conditional Formatting for</property>
+ <property name="resizable">False</property>
+ <property name="type_hint">dialog</property>
+ <child>
+ <placeholder/>
+ </child>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox1">
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="vexpand">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="ok">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="cancel">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="help">
+ <property name="label">gtk-help</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ <property name="secondary">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkFrame" id="framecondition">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="label_xalign">0</property>
+ <property name="shadow_type">none</property>
+ <child>
+ <object class="GtkAlignment" id="alignment1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="vexpand">True</property>
+ <property name="top_padding">6</property>
+ <property name="bottom_padding">6</property>
+ <property name="left_padding">12</property>
+ <property name="right_padding">12</property>
+ <child>
+ <object class="GtkBox" id="box1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="sclo-ScCondFormatList" id="list:border">
+ <property name="width_request">1</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="margin_bottom">10</property>
+ <property name="hexpand">False</property>
+ <property name="vexpand">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButtonBox" id="buttonbox1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="spacing">3</property>
+ <property name="layout_style">start</property>
+ <child>
+ <object class="GtkButton" id="add">
+ <property name="label">gtk-add</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="delete">
+ <property name="label">gtk-delete</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="up">
+ <property name="label">gtk-go-up</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="down">
+ <property name="label">gtk-go-down</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes" context="conditionalformatdialogmobile|label1">Conditions</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkFrame" id="framerange">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label_xalign">0</property>
+ <property name="shadow_type">none</property>
+ <child>
+ <object class="GtkAlignment" id="alignment2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="top_padding">6</property>
+ <property name="bottom_padding">6</property>
+ <property name="left_padding">12</property>
+ <property name="right_padding">12</property>
+ <child>
+ <object class="GtkBox" id="box2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="ftassign">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="valign">center</property>
+ <property name="label" translatable="yes" context="conditionalformatdialogmobile|ftassign">Range:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">edassign</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="foruilo-RefEdit" id="edassign">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="valign">center</property>
+ <property name="hexpand">True</property>
+ <property name="invisible_char">●</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="foruilo-RefButton" id="rbassign">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="valign">center</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes" context="conditionalformatdialogmobile|label2">Cell Range</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">ok</action-widget>
+ <action-widget response="0">cancel</action-widget>
+ <action-widget response="0">help</action-widget>
+ </action-widgets>
+ </object>
+</interface>
diff --git a/solenv/sanitizers/ui/modules/scalc.suppr b/solenv/sanitizers/ui/modules/scalc.suppr
index 3ce7f2635669..9bdb93a34d58 100644
--- a/solenv/sanitizers/ui/modules/scalc.suppr
+++ b/solenv/sanitizers/ui/modules/scalc.suppr
@@ -23,6 +23,26 @@ sc/uiconfig/scalc/ui/conditionalentry.ui://foruilo-RefEdit[@id='val1'] no-labell
sc/uiconfig/scalc/ui/conditionalentry.ui://foruilo-RefEdit[@id='val2'] no-labelled-by
sc/uiconfig/scalc/ui/conditionalentry.ui://GtkComboBoxText[@id='iconsettype'] no-labelled-by
sc/uiconfig/scalc/ui/conditionalentry.ui://foruilo-RefEdit[@id='formula'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkLabel[@id='number'] orphan-label
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkLabel[@id='condition'] orphan-label
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='type'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkLabel[@id='valueft'] orphan-label
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkEntry[@id='edcolscalemin'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkEntry[@id='edcolscalemiddle'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkEntry[@id='edcolscalemax'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://svxcorelo-SvxColorListBox[@id='lbcolmin'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://svxcorelo-SvxColorListBox[@id='lbcolmiddle'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://svxcorelo-SvxColorListBox[@id='lbcolmax'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='colscalemin'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='colscalemiddle'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='colscalemax'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='typeis'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='datetype'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='colorformat'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://foruilo-RefEdit[@id='val1'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://foruilo-RefEdit[@id='val2'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://GtkComboBoxText[@id='iconsettype'] no-labelled-by
+sc/uiconfig/scalc/ui/conditionalentrymobile.ui://foruilo-RefEdit[@id='formula'] no-labelled-by
sc/uiconfig/scalc/ui/conditionaliconset.ui://GtkLabel[@id='label'] orphan-label
sc/uiconfig/scalc/ui/conditionaliconset.ui://GtkEntry[@id='entry'] no-labelled-by
sc/uiconfig/scalc/ui/conditionaliconset.ui://GtkComboBoxText[@id='listbox'] no-labelled-by
commit 3da2462be2eabb8a030cff297345fdbbd494ee5b
Author: Muhammet Kara <muhammet.kara at collabora.com>
AuthorDate: Mon Jul 29 20:27:24 2019 +0300
Commit: Andras Timar <andras.timar at collabora.com>
CommitDate: Tue Sep 3 21:42:32 2019 +0200
lok: Add isMobile() method
[ Miklos: this allows core to e.g. serve tunelled dialogs with more or
less compact layouts, depending on if the client is mobile or not. ]
(cherry picked from commit 4e144c1ab2ae7ef0a7928f7d4685aabe8e6b9c18)
Change-Id: I3559bee84e6ef6f757809617e303aa090698ce5d
Reviewed-on: https://gerrit.libreoffice.org/78306
Reviewed-by: Andras Timar <andras.timar at collabora.com>
Tested-by: Andras Timar <andras.timar at collabora.com>
diff --git a/comphelper/source/misc/lok.cxx b/comphelper/source/misc/lok.cxx
index 4e8f7af1f672..a5d9689137d0 100644
--- a/comphelper/source/misc/lok.cxx
+++ b/comphelper/source/misc/lok.cxx
@@ -22,6 +22,8 @@ namespace LibreOfficeKit
static bool g_bActive(false);
+static bool g_bMobile(false);
+
static bool g_bPartInInvalidation(false);
static bool g_bTiledPainting(false);
@@ -53,6 +55,16 @@ bool isActive()
return g_bActive;
}
+void setMobile(bool bIsMobile)
+{
+ g_bMobile = bIsMobile;
+}
+
+bool isMobile()
+{
+ return g_bMobile;
+}
+
void setPartInInvalidation(bool bPartInInvalidation)
{
g_bPartInInvalidation = bPartInInvalidation;
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index e0e8aca13776..81bb6af9f9a0 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -3195,6 +3195,18 @@ static void doc_postUnoCommand(LibreOfficeKitDocument* pThis, const char* pComma
if (nView < 0)
return;
+ // Set/unset mobile view for LOK
+ if (gImpl && aCommand == ".uno:LOKSetMobile")
+ {
+ comphelper::LibreOfficeKit::setMobile();
+ return;
+ }
+ else if (gImpl && aCommand == ".uno:LOKUnSetMobile")
+ {
+ comphelper::LibreOfficeKit::setMobile(false);
+ return;
+ }
+
// handle potential interaction
if (gImpl && aCommand == ".uno:Save")
{
diff --git a/include/comphelper/lok.hxx b/include/comphelper/lok.hxx
index 34b4259e60dc..4d5748c8f78f 100644
--- a/include/comphelper/lok.hxx
+++ b/include/comphelper/lok.hxx
@@ -29,6 +29,9 @@ namespace LibreOfficeKit
COMPHELPER_DLLPUBLIC void setActive(bool bActive = true);
+// Set LOK view to mobile
+COMPHELPER_DLLPUBLIC void setMobile(bool bIsMobile = true);
+
enum class statusIndicatorCallbackType { Start, SetValue, Finish };
COMPHELPER_DLLPUBLIC void setStatusIndicatorCallback(void (*callback)(void *data, statusIndicatorCallbackType type, int percent), void *data);
@@ -39,6 +42,9 @@ COMPHELPER_DLLPUBLIC void setStatusIndicatorCallback(void (*callback)(void *data
// Check whether the code is running as invoked through LibreOfficeKit.
COMPHELPER_DLLPUBLIC bool isActive();
+// Check whether we are serving to a mobile view/device
+COMPHELPER_DLLPUBLIC bool isMobile();
+
/// Shift the coordinates before rendering each bitmap.
/// Used by Calc to render each tile separately.
/// This should be unnecessary (and removed) once Calc
More information about the Libreoffice-commits
mailing list