Download it now!
Bug 47958 - gross cut/paste signal emission nonsense
Summary: gross cut/paste signal emission nonsense
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
Master old -3.6
Hardware: Other All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:4.2.0
Keywords: difficultyInteresting, easyHack, skillCpp, topicCleanup
Depends on:
Blocks:
 
Reported: 2012-03-27 11:28 UTC by Michael Meeks
Modified: 2016-02-18 16:37 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Meeks 2012-03-27 11:28:12 UTC
If you do:

$ git grep -3 'i97876'

You can see all the instances where someone [!] has cut/pasted a bunch of near-identical code to emit UNO callbacks on the model.

This needs to be turned into a (perhaps several) pleasant helper functions on the model and all mention of that issue expunged.

Bonus points are awarded ;-) for a clean solution that doesn't involve client code having to emit the model's signals itself - while keeping the reasonably efficient single emission for multiple ranges functionality :-)

Thanks !
Comment 1 Roman Eisele 2012-05-04 07:26:05 UTC
This is a Calc issue, therefore changed the 'Component' field accordingly.
Comment 2 Florian Reisinger 2012-05-18 09:29:19 UTC
Deleted "Easyhack" from summary.
Comment 3 Jean-Tiare LE BIGOT 2012-07-14 18:00:12 UTC
I'd like to work on it to get 'a first taste' of how LO is written. Is there any special procedure to do ?
Comment 4 Michael Meeks 2012-07-16 09:11:18 UTC
I suggest we add a method to sc/source/ui/inc/docsh.hxx and sc/source/ui/docshell/docsh.cxx to emit this signal - that includes the code that is cut/pasted everywhere.

Then cleanup all these instances, and any others that are not annotated with that bug to use your new method :-)

Shouldn't be so hard I hope.
Comment 5 Jean-Tiare LE BIGOT 2012-07-24 00:05:00 UTC
I've submitted a patch for this on: https://gerrit.libreoffice.org/#/c/337/. I hope it's all right.
Comment 6 Kohei Yoshida 2012-07-24 15:19:02 UTC
I gave my approval for your commit on gerrit.  I'm not too used to using gerrit, so I'm not sure if I did it right, or I need to do anything more to push your commit to master...
Comment 7 Jean-Tiare LE BIGOT 2012-07-24 18:21:13 UTC
Thanks ! I guess someone still needs to verify/push the code but I have no clue who may do this...
Comment 8 Kohei Yoshida 2012-07-24 18:58:28 UTC
Sorry. there is a merge conflict.  Any chance you can revise your patch?
Comment 9 Jean-Tiare LE BIGOT 2012-07-25 02:07:36 UTC
I'm sorry but I won't go further on this patch. This is just a minor rewrite attempt and is not worth the effort. Moreover, Eike Rathke pointed out in its review that this patch introduces a potential performance regression only to make tha code cleaner. I think it is more valuable to focus on something else.
Comment 10 Björn Michaelsen 2013-10-04 18:47:33 UTC
adding LibreOffice developer list as CC to unresolved EasyHacks for better visibility.

see e.g. http://nabble.documentfoundation.org/minutes-of-ESC-call-td4076214.html for details
Comment 11 Commit Notification 2013-10-15 12:32:20 UTC
Julien Nabet committed a patch related to this issue.
It has been pushed to "master":

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

fdo#47958: gross cut/paste signal emission nonsense



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 12 Commit Notification 2013-10-15 12:32:38 UTC
Caolan McNamara committed a patch related to this issue.
It has been pushed to "master":

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

Resolves: fdo#47958 shrink cut/paste more and rework a bit



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 13 Robinson Tryon (qubit) 2015-12-16 00:36:52 UTC
Migrating Whiteboard tags to Keywords: (EasyHack DifficultyInteresting SkillCpp TopicCleanup )
[NinjaEdit]
Comment 14 Robinson Tryon (qubit) 2016-02-18 16:37:25 UTC
Remove LibreOffice Dev List from CC on EasyHacks
(curtailing excessive email to list)
[NinjaEdit]