[Libreoffice-commits] core.git: sfx2/inc sfx2/source

2022-01-24 Thread Verne-Lai (via logerrit)
 sfx2/inc/autoredactdialog.hxx|7 ++-
 sfx2/source/doc/autoredactdialog.cxx |8 +++-
 2 files changed, 13 insertions(+), 2 deletions(-)

New commits:
commit 687cfd51ac785c2ab2cb8e49dea28aa7f53cbdfb
Author: Verne-Lai 
AuthorDate: Thu Oct 14 09:01:58 2021 +0800
Commit: Eike Rathke 
CommitDate: Mon Jan 24 23:03:05 2022 +0100

tdf#131327 Add double clicked event on auto-redact table

Change-Id: Id927244fcd7e985edadb2b9f9cfdd61ba93066e4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123570
Tested-by: Jenkins
Reviewed-by: Eike Rathke 

diff --git a/sfx2/inc/autoredactdialog.hxx b/sfx2/inc/autoredactdialog.hxx
index fe43eef840f0..28c2c561f60d 100644
--- a/sfx2/inc/autoredactdialog.hxx
+++ b/sfx2/inc/autoredactdialog.hxx
@@ -76,6 +76,11 @@ public:
 
 // Sync data on the targets box with the data on the target
 void setRowData(int nRowIndex, const RedactionTarget* pTarget);
+
+void connect_row_activated(const Link& rLink)
+{
+m_xControl->connect_row_activated(rLink);
+};
 };
 
 namespace sfx2
@@ -110,7 +115,7 @@ class SfxAutoRedactDialog final : public SfxDialogController
 DECL_LINK(AddHdl, weld::Button&, void);
 DECL_LINK(EditHdl, weld::Button&, void);
 DECL_LINK(DeleteHdl, weld::Button&, void);
-
+DECL_LINK(DoubleClickEditHdl, weld::TreeView&, bool);
 DECL_LINK(LoadHdl, sfx2::FileDialogHelper*, void);
 DECL_LINK(SaveHdl, sfx2::FileDialogHelper*, void);
 
diff --git a/sfx2/source/doc/autoredactdialog.cxx 
b/sfx2/source/doc/autoredactdialog.cxx
index a951217fe665..4acbb8ea7816 100644
--- a/sfx2/source/doc/autoredactdialog.cxx
+++ b/sfx2/source/doc/autoredactdialog.cxx
@@ -317,7 +317,12 @@ IMPL_LINK_NOARG(SfxAutoRedactDialog, EditHdl, 
weld::Button&, void)
 // And sync the targets box row with the actual target data
 m_xTargetsBox->setRowData(nSelectedRow, pTarget);
 }
-
+IMPL_LINK_NOARG(SfxAutoRedactDialog, DoubleClickEditHdl, weld::TreeView&, bool)
+{
+if (m_xEditBtn->get_sensitive())
+m_xEditBtn->clicked();
+return true;
+}
 IMPL_LINK_NOARG(SfxAutoRedactDialog, DeleteHdl, weld::Button&, void)
 {
 std::vector aSelectedRows = m_xTargetsBox->get_selected_rows();
@@ -576,6 +581,7 @@ SfxAutoRedactDialog::SfxAutoRedactDialog(weld::Window* 
pParent)
 m_xAddBtn->connect_clicked(LINK(this, SfxAutoRedactDialog, AddHdl));
 m_xEditBtn->connect_clicked(LINK(this, SfxAutoRedactDialog, EditHdl));
 m_xDeleteBtn->connect_clicked(LINK(this, SfxAutoRedactDialog, DeleteHdl));
+m_xTargetsBox->connect_row_activated(LINK(this, SfxAutoRedactDialog, 
DoubleClickEditHdl));
 }
 
 SfxAutoRedactDialog::~SfxAutoRedactDialog()


About libreoffice's GUI development tool

2022-01-11 Thread verne

Hello
I want to know about libreoffice's GUI development
For example: a design tool used by most developers.
Or have other development information about libreoffice's GUI.
Thank you


[Libreoffice-commits] core.git: sw/source

2021-10-08 Thread Verne-Lai (via logerrit)
 sw/source/ui/table/tabledlg.cxx|6 ++
 sw/source/uibase/table/tablepg.hxx |2 +-
 2 files changed, 3 insertions(+), 5 deletions(-)

New commits:
commit 457a67a5b692e79db1aea775e0a2eb48bf1dbdfa
Author: Verne-Lai 
AuthorDate: Fri Oct 8 09:50:05 2021 +0800
Commit: Michael Stahl 
CommitDate: Fri Oct 8 10:22:15 2021 +0200

tdf#143142 Solve the button cannot be used when table column is 6

Change-Id: I6147c08ec36da59bb93b707fa206f9a8f681af3b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123237
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/sw/source/ui/table/tabledlg.cxx b/sw/source/ui/table/tabledlg.cxx
index a797a69f1af2..8b46688ba969 100644
--- a/sw/source/ui/table/tabledlg.cxx
+++ b/sw/source/ui/table/tabledlg.cxx
@@ -742,14 +742,12 @@ SwTableColumnPage::SwTableColumnPage(weld::Container* 
pPage, weld::DialogControl
 m_xBuilder->weld_metric_spin_button("width2", 
FieldUnit::CM),
 m_xBuilder->weld_metric_spin_button("width3", 
FieldUnit::CM),
 m_xBuilder->weld_metric_spin_button("width4", 
FieldUnit::CM),
-m_xBuilder->weld_metric_spin_button("width5", 
FieldUnit::CM),
-m_xBuilder->weld_metric_spin_button("width6", 
FieldUnit::CM) }
+m_xBuilder->weld_metric_spin_button("width5", 
FieldUnit::CM)}
 , m_aTextArr { m_xBuilder->weld_label("1"),
m_xBuilder->weld_label("2"),
m_xBuilder->weld_label("3"),
m_xBuilder->weld_label("4"),
-   m_xBuilder->weld_label("5"),
-   m_xBuilder->weld_label("6") }
+   m_xBuilder->weld_label("5")}
 , m_xModifyTableCB(m_xBuilder->weld_check_button("adaptwidth"))
 , m_xProportionalCB(m_xBuilder->weld_check_button("adaptcolumns"))
 , m_xSpaceFT(m_xBuilder->weld_label("spaceft"))
diff --git a/sw/source/uibase/table/tablepg.hxx 
b/sw/source/uibase/table/tablepg.hxx
index 7c3a4ceea816..4aa1c6d3faf6 100644
--- a/sw/source/uibase/table/tablepg.hxx
+++ b/sw/source/uibase/table/tablepg.hxx
@@ -88,7 +88,7 @@ public:
 };
 
 // TabPage Format/Table/Columns
-#define MET_FIELDS 6 //Number of the used MetricFields
+#define MET_FIELDS 5 //Number of the used MetricFields
 
 class SwTableColumnPage : public SfxTabPage
 {


[Libreoffice-commits] core.git: vbahelper/source

2021-10-04 Thread Verne-Lai (via logerrit)
 vbahelper/source/vbahelper/vbaeventshelperbase.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit dad5b69b229047e0bba921f1856ce26183a5
Author: Verne-Lai 
AuthorDate: Fri Oct 1 11:09:59 2021 +0800
Commit: Michael Stahl 
CommitDate: Mon Oct 4 11:21:34 2021 +0200

[tdf#42982]Improve runtimeException's Message

Change-Id: Ieb1bc302c2c1093561082704e26e3ff3b648db91
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122902
Tested-by: Jenkins
Reviewed-by: Michael Stahl 

diff --git a/vbahelper/source/vbahelper/vbaeventshelperbase.cxx 
b/vbahelper/source/vbahelper/vbaeventshelperbase.cxx
index 1396c93cd616..8c8515d8fa1c 100644
--- a/vbahelper/source/vbahelper/vbaeventshelperbase.cxx
+++ b/vbahelper/source/vbahelper/vbaeventshelperbase.cxx
@@ -277,7 +277,7 @@ OUString VbaEventsHelperBase::getEventHandlerPath( const 
EventHandlerInfo& rInfo
 break;
 
 default:
-throw uno::RuntimeException(); // unsupported module type
+throw uno::RuntimeException("This module type is unsupported"); // 
unsupported module type
 }
 
 /*  Performance improvement: Check the list of existing event handlers