--===============1341679401== Content-Type: multipart/signed; boundary="nextPart1362896.DNNaAoakck"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit --nextPart1362896.DNNaAoakck Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Am Donnerstag, 24. M=E4rz 2005 20:58 schrieben Sie: > Reinhold Kainhofer, you wrote something like this: > > Wouldn't it be simpler to use KURLDrag for dropping attachments instead > > of a QTextDrag and explicitly checking if the dropped text was a URL? > > This would allow it to also drop e.g. the current location of konqueror > > (the web-browser) and not only the location of konqueror (the file > > manager).... > > You're right. I just dived into the DND-semantics of Qt/KDE. I didn't know > the KURLDrag class, but it would probably be better. > > I will see if I can implement this in the todo view shortly. Once I'm > finished with hacking the KOAgendaView and KOMonthView, I'll use KURLDrag > there too. Hmm, thinking of it, we basically have the same drop code in the agenda ite= ms,=20 the to-do list items, and in the future also in the month view items. (The= =20 list view is totally missing them right now.) Basically, when dropping there are two cases: =2D) dropped on an item with an Incidence*. In that case, all views should= =20 behave exactly the same. (Even dropping a to-do on another to-do in the=20 agenda view should make it a sub-to-do...). =2D) dropped on something else (background, empty space in the agenda etc).= Here=20 we have a date/time or not. Depending on the view, a new event or to-do wit= h=20 that datetime should be created. There's also nothing that depends on the=20 view. I wonder if we can't factor that whole stuff out and avoid lot of code=20 duplication.=20 In the drop code we need to have the incidence changer, the calendar and th= e=20 target Incidence* available, and we need to emit signals, so it will not be= =20 as simple as the UrlHandler in korganizer. Moving these functions to the=20 KOrg::BaseView class is also no solution since they'll still not be availab= le=20 e.g. to the agenda items.=20 It's basically the same problem as with the IncidenceChanger, which is also= =20 not solved in a nice way. Currently, the IncidenceChanger* is passed throug= h=20 to each view, and each view holds the same pointer to it. A quasi-global=20 variable would be best, but the changer is specific to the calendarview (an= d=20 thus the Calendar-derived object), so it can't be a singleton. Any better ideas? Cheers, Reinhold =2D-=20 =2D----------------------------------------------------------------- Reinhold Kainhofer, Vienna, Austria email: reinhold@kainhofer.com, http://reinhold.kainhofer.com/ * Financial and Actuarial Mathematics, TU Wien, http://www.fam.tuwien.ac.at * K Desktop Environment, http://www.kde.org/, KOrganizer / KPilot maintain= er --nextPart1362896.DNNaAoakck Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQBCQydITqjEwhXvPN0RAuwVAKDLGSxs5GyKplhrfodBmY/dHTrF0QCg3cMs COQIL38rBuqMQFSjC9c4xbo= =OfYJ -----END PGP SIGNATURE----- --nextPart1362896.DNNaAoakck-- --===============1341679401== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ kde-pim mailing list kde-pim@kde.org https://mail.kde.org/mailman/listinfo/kde-pim kde-pim home page at http://pim.kde.org/ --===============1341679401==--