Review Request 126761: [OS X] handle LaunchServices requests to open files (i.e. from the Finder)

René J.V. Bertin rjvbertin at gmail.com
Mon Jan 18 15:39:56 UTC 2016



> On Jan. 17, 2016, 1:08 p.m., Milian Wolff wrote:
> > app/main.cpp, line 93
> > <https://git.reviewboard.kde.org/r/126761/diff/1/?file=431004#file431004line93>
> >
> >     rename to `startHandleFileOpenEvents`.
> >     
> >     why can't you do this from the beginning btw? i.e. plain `event` overload instead of an event filter on yourself?
> 
> René J.V. Bertin wrote:
>     My initial approach installed the event filter in the KDevelopApplication ctor. The problem with that is that `FileOpen` events can be caught too early in that case. One of the effects of that was that "opening" a file in KDevelop through the Finder would not hand the file off to the selected session, when multiple sessions were open and I picked a specific session. Or it would, but another session would be activated. It took me a while to figure out why that happened, and also to find the most appropriate place to install the event filter.
>     
>     Is that a sufficient and acceptable answer?

I used `startHandlingFileOpenEvents` which is more correct grammatically and contrasts better with the new `handleQueuedFileOpenRequests`.


> On Jan. 17, 2016, 1:08 p.m., Milian Wolff wrote:
> > app/main.cpp, line 259
> > <https://git.reviewboard.kde.org/r/126761/diff/1/?file=431004#file431004line259>
> >
> >     remove the whole conditoinal. you append to the list just before this line, it cannot ever be empty
> >     
> >     then remove the fileList altogether and simply pass `openFilesInRunningInstance({{foe->file()}}, pid)` below. Afaik that should work.

Dropping this as the list is required for queuing events.


- René J.V.


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/126761/#review91197
-----------------------------------------------------------


On Jan. 15, 2016, 4:50 p.m., René J.V. Bertin wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/126761/
> -----------------------------------------------------------
> 
> (Updated Jan. 15, 2016, 4:50 p.m.)
> 
> 
> Review request for KDevelop.
> 
> 
> Repository: kdevelop
> 
> 
> Description
> -------
> 
> This patch introduces support for file open requests from for instance the Finder, on OS X. It also makes it possible to launch KDevelop from the Finder (or the Dock) with the Command key held, in which case the session picker dialog will be presented if multiple sessions are open.
> 
> 
> Diffs
> -----
> 
>   app/Info.plist.in be256f9 
>   app/main.cpp b5f7bb9 
> 
> Diff: https://git.reviewboard.kde.org/r/126761/diff/
> 
> 
> Testing
> -------
> 
> On OS X 10.9.5 with Qt 5.5.1 and KF5 Frameworks 5.17.0 installed in /opt/local
> 
> 
> Thanks,
> 
> René J.V. Bertin
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20160118/9b80f19c/attachment-0001.html>


More information about the KDevelop-devel mailing list