<commit_before>/*
   Bacula® - The Network Backup Solution

   Copyright (C) 2007-2007 Free Software Foundation Europe e.V.

   The main author of Bacula is <NAME>, with contributions from
   many others, a complete list can be found in the file AUTHORS.
   This program is Free Software; you can redistribute it and/or
   modify it under the terms of version two of the GNU General Public
   License as published by the Free Software Foundation plus additions
   that are listed in the file LICENSE.

   This program is distributed in the hope that it will be useful, but
   WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
   General Public License for more details.

   You should have received a copy of the GNU General Public License
   along with this program; if not, write to the Free Software
   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
   02110-1301, USA.

   Bacula® is a registered trademark of <NAME>.
   The licensor of Bacula is the Free Software Foundation Europe
   (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich,
   Switzerland, email:<EMAIL>.
*/

/* 
 *   Version $Id$
 *
 * qt-console main window class definition.
 *
 *  Written by <NAME>, <NAME>
 */

#ifndef _MAINWIN_H_
#define _MAINWIN_H_

#include <QtGui>
#include <QList>
#include "ui_main.h"
#include "label/label.h"
#include "run/run.h"
#include "restore/restore.h"
#include "medialist/medialist.h"

class Console;

class MainWin : public QMainWindow, public Ui::MainForm    
{
   Q_OBJECT

public:
   MainWin(QWidget *parent = 0);
   void set_statusf(const char *fmt, ...);
   void set_status_ready();
   void set_status(const char *buf);
   void writeSettings();
   void readSettings();
   void resetFocus() { lineEdit->setFocus(); };


public slots:
   void input_line();
   void about();
   void treeItemClicked(QTreeWidgetItem *item, int column);
   void treeItemDoubleClicked(QTreeWidgetItem *item, int column);
   void labelDialogClicked();
   void runDialogClicked();
   void restoreDialogClicked();
   void floatWindow();
   void floatWindowButton();

protected:
   void closeEvent(QCloseEvent *event);
   void keyPressEvent(QKeyEvent *event);

private:
   void createConnections(); 
   void createPages();
   QTreeWidgetItem *createTopPage(char *name );
   QTreeWidgetItem *createPage(char *name, QTreeWidgetItem *parent );

private:
   QString m_UserInput;
   Console *m_console;
   BatStack *m_bstackpophold;
   QList<BatStack*> m_bstacklist;
   QList<BatStack*> m_bstackindex;
   QStringList m_cmd_history;
   int m_cmd_last;
   int m_pages;
};

#endif /* _MAINWIN_H_ */<commit_msg>Eliminate unused variable<commit_after>/*
   Bacula® - The Network Backup Solution

   Copyright (C) 2007-2007 Free Software Foundation Europe e.V.

   The main author of Bacula is <NAME>, with contributions from
   many others, a complete list can be found in the file AUTHORS.
   This program is Free Software; you can redistribute it and/or
   modify it under the terms of version two of the GNU General Public
   License as published by the Free Software Foundation plus additions
   that are listed in the file LICENSE.

   This program is distributed in the hope that it will be useful, but
   WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
   General Public License for more details.

   You should have received a copy of the GNU General Public License
   along with this program; if not, write to the Free Software
   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
   02110-1301, USA.

   Bacula® is a registered trademark of <NAME>.
   The licensor of Bacula is the Free Software Foundation Europe
   (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich,
   Switzerland, email:<EMAIL>.
*/

/* 
 *   Version $Id$
 *
 * qt-console main window class definition.
 *
 *  Written by <NAME>, <NAME>
 */

#ifndef _MAINWIN_H_
#define _MAINWIN_H_

#include <QtGui>
#include <QList>
#include "ui_main.h"
#include "label/label.h"
#include "run/run.h"
#include "restore/restore.h"
#include "medialist/medialist.h"

class Console;

class MainWin : public QMainWindow, public Ui::MainForm    
{
   Q_OBJECT

public:
   MainWin(QWidget *parent = 0);
   void set_statusf(const char *fmt, ...);
   void set_status_ready();
   void set_status(const char *buf);
   void writeSettings();
   void readSettings();
   void resetFocus() { lineEdit->setFocus(); };


public slots:
   void input_line();
   void about();
   void treeItemClicked(QTreeWidgetItem *item, int column);
   void treeItemDoubleClicked(QTreeWidgetItem *item, int column);
   void labelDialogClicked();
   void runDialogClicked();
   void restoreDialogClicked();
   void floatWindow();
   void floatWindowButton();

protected:
   void closeEvent(QCloseEvent *event);
   void keyPressEvent(QKeyEvent *event);

private:
   void createConnections(); 
   void createPages();
   QTreeWidgetItem *createTopPage(char *name );
   QTreeWidgetItem *createPage(char *name, QTreeWidgetItem *parent );

private:
   Console *m_console;
   BatStack *m_bstackpophold;
   QList<BatStack*> m_bstacklist;
   QList<BatStack*> m_bstackindex;
   QStringList m_cmd_history;
   int m_cmd_last;
   int m_pages;
};

#endif /* _MAINWIN_H_ */
{'fraction_non_alphanumeric': 0.08535674262233844, 'fraction_numerical': 0.009712364587224505, 'mean_word_length': 3.9953358208955225, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5807774', 'n_tokens_mistral': 1669, 'n_tokens_neox': 1603, 'n_words': 596}