Bug 117821 - Editing: Forms: Replace control menu selection image button places wrong control type on form (combo box)
Summary: Editing: Forms: Replace control menu selection image button places wrong cont...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
5.4.4.2 release
Hardware: All All
: medium normal
Assignee: Julien Nabet
URL:
Whiteboard: target:6.2.0 target:6.0.5 target:6.1.0.1
Keywords: regression
Depends on:
Blocks:
 
Reported: 2018-05-26 15:07 UTC by Drew Jensen
Modified: 2018-05-27 07:33 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
example ODB file (firebird) (35.80 KB, application/vnd.oasis.opendocument.database)
2018-05-26 15:12 UTC, Drew Jensen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Drew Jensen 2018-05-26 15:07:18 UTC
Description:
When editing a form the user can change a control from one type to another via a context menu item. Checking each of these the selection for Image Button places a comboBox control instead. All the other menu items work as expected.

Tested this on Ubuntu 18.04 64bit,  with build:
Version: 6.2.0.0.alpha0+
Build ID: c0fbf99e5601da27c59d131bcca24fafd259e508
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk2; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2018-05-24_22:08:37
Locale: en-US (en_US.UTF-8); Calc: group threaded


Steps to Reproduce:
1. download and open the attached ODB file (embedded firebird)
2. open the form "tbl_varbinary2" in edit mode
3. CTRL/Click inside the second text control on the form (labeled "tst_data")
4. With only the control now selected, right mouse click for context menu
5. Select "Replace control with"
6. From the selection of controls, select "Image Button"

Actual Results:  
The Text Box control is replaced with a Combo Box control.

Expected Results:
The Text Box control is replaced with a Image Button


Reproducible: Always


User Profile Reset: No



Additional Info:


User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/66.0.3359.181 Chrome/66.0.3359.181 Safari/537.36
Comment 1 Drew Jensen 2018-05-26 15:12:54 UTC
Created attachment 142295 [details]
example ODB file (firebird)
Comment 2 Drew Jensen 2018-05-26 15:14:56 UTC
Changing version this effects, checked with 6.0.3 (release Ubuntu repo) and 5.4.8 (daily build) each has the problem. 
// ps there doesn't seem to be a selection for this particular 5.4 build so I choose the closest
Comment 3 Robert Großkopf 2018-05-26 15:51:02 UTC
Seems this has been introduced with the solution of another bug.
With LO 5.4.0.3 it has been impossible to change a control from one type to another. This has been fixed later but the connection has been set wrong.

By the way: What do you wan't to do with the image-button? Isn't working since the beginning of LO: https://bugs.documentfoundation.org/show_bug.cgi?id=46579
Comment 4 Drew Jensen 2018-05-26 16:04:02 UTC
(In reply to robert from comment #3)
> Seems this has been introduced with the solution of another bug.
> With LO 5.4.0.3 it has been impossible to change a control from one type to
> another. This has been fixed later but the connection has been set wrong.
> 
> By the way: What do you wan't to do with the image-button? Isn't working
> since the beginning of LO:
> https://bugs.documentfoundation.org/show_bug.cgi?id=46579

Huh

Just opened and old file (built in 2009 and uses HSQL embedded engine) which extensively uses image buttons which call macros when clicked, the forms work fine in 6.2Alpha0 (and I tried them in 6.1 and 6.0) all good.

IDK Maybe it is because it was created with an old version of Base.
Comment 5 Robert Großkopf 2018-05-26 16:53:01 UTC
> 
> Just opened and old file (built in 2009 and uses HSQL embedded engine) which
> extensively uses image buttons which call macros when clicked, the forms
> work fine in 6.2Alpha0 (and I tried them in 6.1 and 6.0) all good.

Macros aren't the problem. For "normal users" there you could choose actions for the control - but no action you could choose will work.
Comment 6 Julien Nabet 2018-05-26 19:30:43 UTC
On pc Debian x86-64 with master sources updated today, I could reproduce this.

I'll take this.
Comment 7 Julien Nabet 2018-05-26 19:34:46 UTC
Patch waiting for review here:
https://gerrit.libreoffice.org/#/c/54865/
Comment 8 Commit Notification 2018-05-27 05:58:01 UTC
Julien Nabet committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=1e9e01dff0a8d65bb10d5a886cca7899b43979da

tdf#117821: fix copy-paste wrong control type

It will be available in 6.2.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 9 Julien Nabet 2018-05-27 06:01:49 UTC
I've just submitted for review:
- 6.1 branch: https://gerrit.libreoffice.org/#/c/54870/
- 6.0 branch: https://gerrit.libreoffice.org/#/c/54871/
Comment 10 Commit Notification 2018-05-27 07:32:59 UTC
Julien Nabet committed a patch related to this issue.
It has been pushed to "libreoffice-6-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=694e18cffd8cadc70e76c2b18b614b5ccceafefd&h=libreoffice-6-0

tdf#117821: fix copy-paste wrong control type

It will be available in 6.0.5.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 11 Commit Notification 2018-05-27 07:33:07 UTC
Julien Nabet committed a patch related to this issue.
It has been pushed to "libreoffice-6-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=afa0d13b528a5afe453bc2fa501b6dbc8d6804b5&h=libreoffice-6-1

tdf#117821: fix copy-paste wrong control type

It will be available in 6.1.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.