catch markup exceptions cleanups
2006-08-24 Bart Hakvoort <hakvoort@cvs.gnome.org> * src/OperationDetail.cc: catch markup exceptions * src/Utils.cc: cleanups
This commit is contained in:
parent
e58a5f3cf7
commit
5631232ee1
|
@ -1,3 +1,8 @@
|
|||
2006-08-24 Bart Hakvoort <hakvoort@cvs.gnome.org>
|
||||
|
||||
* src/OperationDetail.cc: catch markup exceptions
|
||||
* src/Utils.cc: cleanups
|
||||
|
||||
2006-08-21 Bart Hakvoort <hakvoort@cvs.gnome.org>
|
||||
|
||||
* include/Utils.h,
|
||||
|
|
|
@ -40,20 +40,27 @@ OperationDetail::OperationDetail( const Glib::ustring & description, OperationDe
|
|||
|
||||
void OperationDetail::set_description( const Glib::ustring & description, Font font )
|
||||
{
|
||||
switch ( font )
|
||||
try
|
||||
{
|
||||
case FONT_NORMAL:
|
||||
this ->description = Glib::Markup::escape_text( description ) ;
|
||||
break ;
|
||||
case FONT_BOLD:
|
||||
this ->description = "<b>" + Glib::Markup::escape_text( description ) + "</b>" ;
|
||||
break ;
|
||||
case FONT_ITALIC:
|
||||
this ->description = "<i>" + Glib::Markup::escape_text( description ) + "</i>" ;
|
||||
break ;
|
||||
case FONT_BOLD_ITALIC:
|
||||
this ->description = "<b><i>" + Glib::Markup::escape_text( description ) + "</i></b>" ;
|
||||
break ;
|
||||
switch ( font )
|
||||
{
|
||||
case FONT_NORMAL:
|
||||
this ->description = Glib::Markup::escape_text( description ) ;
|
||||
break ;
|
||||
case FONT_BOLD:
|
||||
this ->description = "<b>" + Glib::Markup::escape_text( description ) + "</b>" ;
|
||||
break ;
|
||||
case FONT_ITALIC:
|
||||
this ->description = "<i>" + Glib::Markup::escape_text( description ) + "</i>" ;
|
||||
break ;
|
||||
case FONT_BOLD_ITALIC:
|
||||
this ->description = "<b><i>" + Glib::Markup::escape_text( description ) + "</i></b>" ;
|
||||
break ;
|
||||
}
|
||||
}
|
||||
catch ( Glib::Exception & e )
|
||||
{
|
||||
this ->description = e .what() ;
|
||||
}
|
||||
|
||||
on_update( *this ) ;
|
||||
|
|
|
@ -253,9 +253,6 @@ int Utils::execute_command( const Glib::ustring & command,
|
|||
{
|
||||
error = e .what() ;
|
||||
|
||||
//spit exceptions to stdout..
|
||||
std::cout << error << std::endl ;
|
||||
|
||||
return -1 ;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue