X-Git-Url: https://vaikene.ee/gitweb/pswgen11.html?a=blobdiff_plain;f=src%2Fapps%2FPswGen%2FStorage%2Fistorage.h;h=48226d0ec7a6d66b18c2d1ab7171e991b01c7968;hb=8ca71a4ced13c50ecd1e3b9d9c15546ac0d48045;hp=6560553fd0d3516a6200359b7f5e93f480ad2774;hpb=4a856bc600d1819e01c797881e0591810737c2fd;p=evaf
diff --git a/src/apps/PswGen/Storage/istorage.h b/src/apps/PswGen/Storage/istorage.h
index 6560553..48226d0 100644
--- a/src/apps/PswGen/Storage/istorage.h
+++ b/src/apps/PswGen/Storage/istorage.h
@@ -20,8 +20,6 @@
#ifndef __PSWGEN_STORAGE_ISTORAGE_H
# define __PSWGEN_STORAGE_ISTORAGE_H
-#include "lib.h"
-
#include
#include
#include
@@ -37,24 +35,29 @@ namespace Storage {
/**
* Data stored for every password.
*/
-class PSWGEN_STORAGE_EXPORT Data : public QSharedData
+class Data : public QSharedData
{
public:
- Data()
+ Data(QString const & name)
: QSharedData()
, mModified(false)
+ , mName(name)
, mLength(0)
, mFlags(0)
{}
- Data(int l, uint f = 0)
+ Data(QString const & name, int l, uint f = 0)
: QSharedData()
, mModified(false)
+ , mName(name)
, mLength(l)
, mFlags(f)
{}
+ /// Name of the password
+ inline QString const & name() const { return mName; }
+
/// Length of the generated password
inline int length() const { return mLength; }
inline void setLength(int value)
@@ -85,6 +88,7 @@ public:
private:
bool mModified;
+ QString mName;
int mLength;
uint mFlags;