1 /*
2 Copyright (C) 2011 Elvis Stansvik <elvstone@gmail.com>
3 
4 For general Scribus (>=1.3.2) copyright and licensing information please refer
5 to the COPYING file provided with the program. Following this notice may exist
6 a copyright and/or license notice that predates the release of Scribus 1.3.2
7 for which a new license (GPL+exception) is in place.
8 */
9 #include "appmodes.h"
10 
11 #include "inserttablerowsdialog.h"
12 
InsertTableRowsDialog(int appMode,QWidget * parent)13 InsertTableRowsDialog::InsertTableRowsDialog(int appMode, QWidget *parent) : QDialog(parent)
14 {
15 	setupUi(this);
16 
17 	positions->setId(beforeButton, Before);
18 	positions->setId(afterButton, After);
19 
20 	if (appMode == modeEditTable)
21 	{
22 		// In table edit mode we insert before/after current row.
23 		beforeButton->setText(tr("Before"));
24 		afterButton->setText(tr("After"));
25 	}
26 	else
27 	{
28 		// Otherwise we insert at table beginning/end.
29 		beforeButton->setText(tr("Beginning"));
30 		afterButton->setText(tr("End"));
31 	}
32 }
33