diff --git a/ChangeLog b/ChangeLog index 83342e0a..8ae23b74 100644 --- a/ChangeLog +++ b/ChangeLog @@ -24992,3 +24992,5 @@ * Cleaned up compiler warnings in 'rdairplay/'. 2025-04-26 Fred Gleason * Cleaned up compiler warnings in 'rdcatch/'. +2025-04-26 Fred Gleason + * Cleaned up compiler warnings in 'rdlibrary/'. diff --git a/rdlibrary/disk_gauge.cpp b/rdlibrary/disk_gauge.cpp index 36f43ca6..44a15354 100644 --- a/rdlibrary/disk_gauge.cpp +++ b/rdlibrary/disk_gauge.cpp @@ -2,7 +2,7 @@ // // Disk Gauge Widget for RDLibrary. // -// (C) Copyright 2002-2022 Fred Gleason +// (C) Copyright 2002-2025 Fred Gleason // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License version 2 as @@ -92,9 +92,9 @@ void DiskGauge::update() void DiskGauge::resizeEvent(QResizeEvent *e) { QFontMetrics *fm=new QFontMetrics(disk_label->font()); - disk_label->setGeometry(0,0,fm->width(disk_label->text()),size().height()/2); - disk_bar->setGeometry(fm->width(disk_label->text())+5,0, - size().width()-fm->width(disk_label->text())-10,size().height()/2); + disk_label->setGeometry(0,0,fm->horizontalAdvance(disk_label->text()),size().height()/2); + disk_bar->setGeometry(fm->horizontalAdvance(disk_label->text())+5,0, + size().width()-fm->horizontalAdvance(disk_label->text())-10,size().height()/2); disk_space_label-> setGeometry(0,size().height()/2,size().width(),size().height()/2); delete fm; diff --git a/rdlibrary/disk_ripper.cpp b/rdlibrary/disk_ripper.cpp index d712cda1..436ac5d4 100644 --- a/rdlibrary/disk_ripper.cpp +++ b/rdlibrary/disk_ripper.cpp @@ -2,7 +2,7 @@ // // CD Disk Ripper Dialog for Rivendell. // -// (C) Copyright 2002-2022 Fred Gleason +// (C) Copyright 2002-2025 Fred Gleason // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License version 2 as @@ -743,7 +743,7 @@ void DiskRipper::mediaChangedData() rip_cutnames.push_back(QString()); rip_end_track.push_back(-1); rip_wave_datas.push_back(new RDWaveData()); - rip_wave_datas.back()->setTitle(tr("Track")+QString().sprintf(" %d",i)); + rip_wave_datas.back()->setTitle(tr("Track")+QString::asprintf(" %d",i)); } rip_disc_record.clear(); rip_cdrom->setCddbRecord(&rip_disc_record); @@ -1206,7 +1206,7 @@ QModelIndexList DiskRipper::SortRows(const QModelIndexList &rows) const modified=false; for(int i=1;irows.at(index.at(i)).row()) { - index.swap(i-1,i); + index.swapItemsAt(i-1,i); modified=true; } } diff --git a/rdlibrary/list_reports.cpp b/rdlibrary/list_reports.cpp index aa0b4b41..b24dd36d 100644 --- a/rdlibrary/list_reports.cpp +++ b/rdlibrary/list_reports.cpp @@ -2,7 +2,7 @@ // // List RDLibrary Reports // -// (C) Copyright 2002-2024 Fred Gleason +// (C) Copyright 2002-2025 Fred Gleason // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License version 2 as @@ -651,7 +651,7 @@ void ListReports::GenerateCartDumpCsv(QString *report,bool prepend_names) *report+=RDCsvField(q->value(30).toInt()); } sql=QString("select `SCHED_CODE` from `CART_SCHED_CODES` where ")+ - QString().sprintf("`CART_NUMBER`=%u",q->value(0).toUInt()); + QString::asprintf("`CART_NUMBER`=%u",q->value(0).toUInt()); QString schedcodes=""; q1=new RDSqlQuery(sql); while(q1->next()) {