X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGEOMToolsGUI%2FGEOMToolsGUI_DeleteDlg.cxx;h=d86e3c051f7cfa03fd7b0a5a1cb905856efab551;hb=fae650357c2256670c6c928993133d7f4478fc38;hp=d2d0dc11f14ded14289999529d13f6ca798869eb;hpb=0b6826bc5f36b5420f41af1475e1a79371a25323;p=modules%2Fgeom.git diff --git a/src/GEOMToolsGUI/GEOMToolsGUI_DeleteDlg.cxx b/src/GEOMToolsGUI/GEOMToolsGUI_DeleteDlg.cxx index d2d0dc11f..d86e3c051 100644 --- a/src/GEOMToolsGUI/GEOMToolsGUI_DeleteDlg.cxx +++ b/src/GEOMToolsGUI/GEOMToolsGUI_DeleteDlg.cxx @@ -1,7 +1,4 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE -// -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2007-2010 CEA/DEN, EDF R&D, OPEN CASCADE // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -19,6 +16,7 @@ // // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // + // GEOM GEOMGUI : GUI for Geometry component // File : GEOMToolsGUI_DeleteDlg.cxx // Author : Dmitry Matveitchev, Open CASCADE S.A.S. @@ -26,7 +24,7 @@ #include "GEOMToolsGUI_DeleteDlg.h" #include -#include +#include #include #include #include @@ -110,21 +108,13 @@ GEOMToolsGUI_DeleteDlg::GEOMToolsGUI_DeleteDlg( QWidget* parent, lab->setText( tr( "GEOM_REALLY_DELETE_ALL" ) ); } - QPushButton* buttonYes = new QPushButton( tr( "GEOM_BUT_YES" ), this ); - QPushButton* buttonNo = new QPushButton( tr( "GEOM_BUT_NO" ), this ); - QHBoxLayout* btnLayout = new QHBoxLayout; - btnLayout->setMargin( 0 ); - btnLayout->setSpacing( 6 ); - btnLayout->addWidget( buttonYes ); - btnLayout->addSpacing( 10 ); - btnLayout->addStretch(); - btnLayout->addWidget( buttonNo ); + QDialogButtonBox* buttonBox = new QDialogButtonBox(QDialogButtonBox::Yes + | QDialogButtonBox::No); int rc = topLayout->rowCount(); - topLayout->addLayout( btnLayout, rc, 0, 1, 2 ); + topLayout->addWidget( buttonBox, rc, 1, 1, 1 ); - /* signals and slots connections */ - connect( buttonYes, SIGNAL( clicked() ), this, SLOT( accept() ) ); - connect( buttonNo, SIGNAL( clicked() ), this, SLOT( reject() ) ); + connect(buttonBox, SIGNAL(accepted()), this, SLOT(accept())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); } GEOMToolsGUI_DeleteDlg::~GEOMToolsGUI_DeleteDlg()