- Added side pane for product preview and information - Product selection is done with a separate pushbutton, so that user gets a chance to preview the complete product information before committing to the selection - Supports two view modes: Grid View and List View - View mode is automatically stored in Settings, so it will default to the user's prefered mode - Should address most concerns in #109 and #142
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
* along with gLabels-qt. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
#include "Settings.h"
|
||||
|
||||
#include <QLocale>
|
||||
@@ -262,6 +263,28 @@ namespace glabels
|
||||
}
|
||||
|
||||
|
||||
QListView::ViewMode Settings::templatePickerMode()
|
||||
{
|
||||
QString defaultMode = "icon";
|
||||
|
||||
mInstance->beginGroup( "TemplatePicker" );
|
||||
QString returnMode = mInstance->value( "viewMode", defaultMode ).toString();
|
||||
mInstance->endGroup();
|
||||
|
||||
return returnMode == "icon" ? QListView::IconMode : QListView::ListMode;
|
||||
}
|
||||
|
||||
|
||||
void Settings::setTemplatePickerMode( QListView::ViewMode viewMode )
|
||||
{
|
||||
mInstance->beginGroup( "TemplatePicker" );
|
||||
mInstance->setValue( "viewMode", viewMode == QListView::IconMode ? "icon" : "list" );
|
||||
mInstance->endGroup();
|
||||
|
||||
emit mInstance->changed();
|
||||
}
|
||||
|
||||
|
||||
QStringList Settings::recentTemplateList()
|
||||
{
|
||||
QStringList defaultList;
|
||||
|
||||
Reference in New Issue
Block a user