- a search request can now be terminated by another

This commit is contained in:
Christophe Dumez 2007-07-22 13:42:09 +00:00
parent f4adf173a2
commit 2c48968a31
3 changed files with 5 additions and 3 deletions

View file

@ -25,6 +25,7 @@
- FEATURE: Added keyboard shortcuts for main actions (see wiki) - FEATURE: Added keyboard shortcuts for main actions (see wiki)
- FEATURE: Added a popup menu to set priority for multiple fies at once - FEATURE: Added a popup menu to set priority for multiple fies at once
- FEATURE: Improved a lot downloading from urls (using libcommoncpp2 instead of libcurl) - FEATURE: Improved a lot downloading from urls (using libcommoncpp2 instead of libcurl)
- FEATURE: A search request can now be terminated by another
- I18N: Added Hungarian translation - I18N: Added Hungarian translation
- BUGFIX: Progress of paused torrents is now correct on restart - BUGFIX: Progress of paused torrents is now correct on restart
- BUGFIX: Progress column gets sorted on restart it is was during last execution - BUGFIX: Progress column gets sorted on restart it is was during last execution

1
TODO
View file

@ -44,7 +44,6 @@
* beta3 * beta3
- Windows port (Chris - Peerkoel) - Windows port (Chris - Peerkoel)
- Translations update - Translations update
- Allow to abort a search by launching another one
* beta2 * beta2
- Wait for some bug fixes in libtorrent : - Wait for some bug fixes in libtorrent :
- upload/download limit per torrent - upload/download limit per torrent

View file

@ -260,6 +260,10 @@ void SearchEngine::saveSearchHistory()
// Function called when we click on search button // Function called when we click on search button
void SearchEngine::on_search_button_clicked(){ void SearchEngine::on_search_button_clicked(){
if(searchProcess->state() != QProcess::NotRunning){
searchProcess->kill();
searchProcess->waitForFinished();
}
QString pattern = search_pattern->text().trimmed(); QString pattern = search_pattern->text().trimmed();
// No search pattern entered // No search pattern entered
if(pattern.isEmpty()){ if(pattern.isEmpty()){
@ -319,8 +323,6 @@ void SearchEngine::on_search_button_clicked(){
void SearchEngine::searchStarted(){ void SearchEngine::searchStarted(){
// Update SearchEngine widgets // Update SearchEngine widgets
search_button->setEnabled(false);
search_button->repaint();
search_status->setText(tr("Searching...")); search_status->setText(tr("Searching..."));
search_status->repaint(); search_status->repaint();
stop_search_button->setEnabled(true); stop_search_button->setEnabled(true);