Help with Qt QStringList

Hello. This is my class:

file .h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#ifndef UNDOREDO_H
#define UNDOREDO_H

#include <QUndoCommand>

typedef QVector<QStringList> vector_t ;

class UndoRedo : public QUndoCommand
 {
 public:

     UndoRedo(QList<vector_t> v,
                    QUndoCommand *parent = 0);

     void undo();

 private:    
     QList<vector_t> *cb_values;
 };

#endif // UNDOREDO_H 


file .cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include "undoredo.h"

UndoRedo::UndoRedo(QList<vector_t> v,
                   QUndoCommand *parent)
    : QUndoCommand(parent)
{

    cb_values = &v;
}

void UndoRedo::undo() {    
    QString last = cb_values[0][0].takeLast();
    qDebug() << last << "removed!";
}


When I call undo() method the IDE raises this error:

error: conversion from 'QStringList' to non-scalar type 'QString' requested

Where am I doing wrong?
Topic archived. No new replies allowed.