From 4ccee8063c471831a34889663aff117616e25c1d Mon Sep 17 00:00:00 2001 From: Mike Fleetwood Date: Sun, 7 Apr 2019 16:08:14 +0100 Subject: [PATCH] Rename method to Dialog_Progress::write_operation_details() And update comment about replacing '\n' to reflect what the code actually does. --- include/Dialog_Progress.h | 4 ++-- src/Dialog_Progress.cc | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/include/Dialog_Progress.h b/include/Dialog_Progress.h index bef03bea..5f8e7ec1 100644 --- a/include/Dialog_Progress.h +++ b/include/Dialog_Progress.h @@ -54,8 +54,8 @@ private: void on_save() ; void write_device_details(const Device& device, std::ofstream& out); void write_partition_details(const Partition& partition, std::ofstream& out); - void echo_operation_details( const OperationDetail & operation_detail, std::ofstream & out ) ; - + void write_operation_details(const OperationDetail& operation_detail, std::ofstream& out); + void on_response( int response_id ) ; bool on_delete_event( GdkEventAny * event ) ; bool pulsebar_pulse(); diff --git a/src/Dialog_Progress.cc b/src/Dialog_Progress.cc index 3c8b56a7..59b921cb 100644 --- a/src/Dialog_Progress.cc +++ b/src/Dialog_Progress.cc @@ -406,7 +406,7 @@ void Dialog_Progress::on_save() for ( unsigned int t = 0 ; t < operations .size() ; t++ ) { out << "

========================================

" << std::endl; - echo_operation_details(operations[t]->operation_detail, out); + write_operation_details(operations[t]->operation_detail, out); } //Write out proper HTML finish @@ -493,9 +493,9 @@ void Dialog_Progress::write_partition_details(const Partition& partition, std::o } -void Dialog_Progress::echo_operation_details( const OperationDetail & operationdetail, std::ofstream & out ) +void Dialog_Progress::write_operation_details(const OperationDetail& operationdetail, std::ofstream& out) { - //replace '\n' with '
' + // Replace '\n' with '
' Glib::ustring temp = operationdetail .get_description() ; for ( unsigned int index = temp .find( "\n" ) ; index < temp .length() ; index = temp .find( "\n" ) ) temp .replace( index, 1, "
" ) ; @@ -573,7 +573,7 @@ void Dialog_Progress::echo_operation_details( const OperationDetail & operationd << "" << std::endl ; for ( unsigned int t = 0 ; t < operationdetail .get_childs() .size() ; t++ ) - echo_operation_details( *(operationdetail.get_childs()[ t ]), out ); + write_operation_details(*(operationdetail.get_childs()[t]), out); out << "" << std::endl << "" << std::endl ; }