From kde-devel Tue Aug 31 12:26:56 1999 From: John Corey Date: Tue, 31 Aug 1999 12:26:56 +0000 To: kde-devel Subject: Re: New KDE Dock Applet X-MARC-Message: https://marc.info/?l=kde-devel&m=93610204519788 Matthias Welk wrote: > > On Mon, 30 Aug 1999, John Corey wrote: > > > Roberto Alsina wrote: > > > > > > On Mon, 30 Aug 1999, ian geiser wrote: > > > > > > > > > > > > Oh, just what I needed. I too have a couple applets > > > > > I've thrown > > > > > together, not working completely yet though. I was > > > > > just starting to > > > > > implement downloading stuff from web pages, so this > > > > > will hopefully make > > > > > that easier to learn. :) > > > > > > > > i am cheating in the way that i am using KFM > > > > to download the file. KFM is damn nice for an > > > > api but i guess the ease of programing makes > > > > for a lack of features. > > > > > > > > if anyone on the list can direct an easy yet > > > > stable way to transfer files less painfully > > > > than KSocket please post it. The main problem > > > > i have with KFM is it brings a window to the > > > > front of the screen. This is a real hassel > > > > when one is TRYING to play XEvil :P > > > > > > Well, KDE 2 fixes that. > > > Simple way to download a file from the web... how about > > > > > > system ("lynx -save http://whatever.com") > > > > > > Not really correct, but it should work. > > > > After downloading this kweather I found it wasn't a kicker applet as I > > assumed since I just had that on my mind working on my programs, but for > > KDE 1.x. But from what I've seen in some other KDE 2 apps, to do this > > is just: > > > > KIOJob *iojob = new KIOJob; > > connect(iojob, SIGNAL(SIGNAL( sigFinished( int ) ), this, > > SLOT(myFinished(int))); > > iojob->copy("http://www.whatever/url/file.html", "file:/tmp/file.html"); > > > > to save that to /tmp/file.html, right? I think it was kghostview that I > > saw doing that, and I checked another couple apps. So I did that in my > > applet, and here's what happens: > > > > 25 iojob->copy(src.data(), dest.data()); > > (gdb) n > > KIOJob::createSlave : Slave got > > kiolib (KIOJob): TRYING TO START /opt/kde-2/bin/kio_http > > trying m_strSlave...Pass > > m_strSlavePass ok (1) > > 28 NewsGroup *group = new NewsGroup("ltoday.rdf"); > > (gdb) Slot copy called with: > > :http://linux/~jcorey/ltoday.rdf:file:/home/jcorey/ltoday.rdf:slotCopy 0 > > BAH > > BAH$ > > slotCopy 3 > > kio_file : Starting > > kio_file : Adding .part extension to /home/jcorey/ltoday.rdf > > kio_http : Copied files file:/home/jcorey/ltoday.rdf > > KILLING SLAVE xb 13766 > > > > ... Apache's log registers the hit, everything looks like it downloaded > > fine, except there's no such file in my home directory, and the slot > > function is never called. I even connected sigError() up, but it's not > > emitted either. Does copy block or should I do everything I need with > > the file in the finished slot function (once it gets working right)? > > > There is a problem with the current kio_http. After download is finished > kio_file deletes the new file again :-( > > I will try to fix that, but it may take a while (I'm very busy). > > Greetings, Matthias. Ah, ok. As long as I'm not going insane, that's fine...