#############################################################################
# Makefile for building: bat
-# Generated by qmake (2.01a) (Qt 4.2.1) on: Sat Feb 3 11:19:57 2007
+# Generated by qmake (2.01a) (Qt 4.2.1) on: Sat Feb 3 13:49:24 2007
# Project: bat.pro
# Template: app
# Command: /usr/bin/qmake -unix -o Makefile bat.pro
CXXFLAGS = -pipe -O2 -Wall -W -D_REENTRANT $(DEFINES)
LEXFLAGS =
YACCFLAGS = -d
-INCPATH = -I/usr/share/qt4/mkspecs/default -I. -I/usr/include/QtCore -I/usr/include/QtCore -I/usr/include/QtGui -I/usr/include/QtGui -I/usr/include -I. -Iconsole -I.. -I. -I.
+INCPATH = -I/usr/share/qt4/mkspecs/default -I. -I/usr/include/QtCore -I/usr/include/QtCore -I/usr/include/QtGui -I/usr/include/QtGui -I/usr/include -I. -Iconsole -Irestore -I.. -I. -I.
LINK = g++
LFLAGS =
LIBS = $(SUBLIBS) -L/usr/lib -L../lib -lbac -lssl -lcrypto -lQtGui -L/usr/lib -L/usr/X11R6/lib -lpng -lSM -lICE -lXi -lXrender -lXrandr -lXfixes -lXcursor -lXinerama -lfreetype -lfontconfig -lXext -lX11 -lQtCore -lz -lm -ldl -lpthread
bat_conf.cpp \
mainwin.cpp \
console/authenticate.cpp \
- console/console.cpp moc_mainwin.cpp \
+ console/console.cpp \
+ restore/brestore.cpp moc_mainwin.cpp \
moc_console.cpp \
+ moc_restore.cpp \
qrc_main.cpp
OBJECTS = main.o \
bat_conf.o \
mainwin.o \
authenticate.o \
console.o \
+ brestore.o \
moc_mainwin.o \
moc_console.o \
+ moc_restore.o \
qrc_main.o
DIST = /usr/share/qt4/mkspecs/common/unix.conf \
/usr/share/qt4/mkspecs/common/g++.conf \
all: Makefile $(TARGET)
-$(TARGET): ui_main.h ui_label.h ui_console.h $(OBJECTS)
+$(TARGET): ui_main.h ui_label.h ui_console.h ui_brestore.h $(OBJECTS)
$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)
Makefile: bat.pro /usr/share/qt4/mkspecs/default/qmake.conf /usr/share/qt4/mkspecs/common/unix.conf \
dist:
@$(CHK_DIR_EXISTS) .tmp/bat1.0.0 || $(MKDIR) .tmp/bat1.0.0
- $(COPY_FILE) --parents $(SOURCES) $(DIST) .tmp/bat1.0.0/ && $(COPY_FILE) --parents mainwin.h bat.h bat_conf.h console/console.h .tmp/bat1.0.0/ && $(COPY_FILE) --parents main.qrc .tmp/bat1.0.0/ && $(COPY_FILE) --parents main.cpp bat_conf.cpp mainwin.cpp console/authenticate.cpp console/console.cpp .tmp/bat1.0.0/ && $(COPY_FILE) --parents main.ui label.ui console/console.ui .tmp/bat1.0.0/ && (cd `dirname .tmp/bat1.0.0` && $(TAR) bat1.0.0.tar bat1.0.0 && $(COMPRESS) bat1.0.0.tar) && $(MOVE) `dirname .tmp/bat1.0.0`/bat1.0.0.tar.gz . && $(DEL_FILE) -r .tmp/bat1.0.0
+ $(COPY_FILE) --parents $(SOURCES) $(DIST) .tmp/bat1.0.0/ && $(COPY_FILE) --parents mainwin.h bat.h bat_conf.h console/console.h restore/restore.h .tmp/bat1.0.0/ && $(COPY_FILE) --parents main.qrc .tmp/bat1.0.0/ && $(COPY_FILE) --parents main.cpp bat_conf.cpp mainwin.cpp console/authenticate.cpp console/console.cpp restore/brestore.cpp .tmp/bat1.0.0/ && $(COPY_FILE) --parents main.ui label.ui console/console.ui restore/brestore.ui .tmp/bat1.0.0/ && (cd `dirname .tmp/bat1.0.0` && $(TAR) bat1.0.0.tar bat1.0.0 && $(COMPRESS) bat1.0.0.tar) && $(MOVE) `dirname .tmp/bat1.0.0`/bat1.0.0.tar.gz . && $(DEL_FILE) -r .tmp/bat1.0.0
yaccclean:
mocables: compiler_moc_header_make_all compiler_moc_source_make_all
-compiler_moc_header_make_all: moc_mainwin.cpp moc_console.cpp
+compiler_moc_header_make_all: moc_mainwin.cpp moc_console.cpp moc_restore.cpp
compiler_moc_header_clean:
- -$(DEL_FILE) moc_mainwin.cpp moc_console.cpp
+ -$(DEL_FILE) moc_mainwin.cpp moc_console.cpp moc_restore.cpp
moc_mainwin.cpp: ui_main.h \
mainwin.h \
/usr/bin/moc
/usr/bin/moc $(DEFINES) $(INCPATH) mainwin.h -o moc_mainwin.cpp
-moc_console.cpp: console/console.h \
+moc_console.cpp: ui_console.h \
+ console/console.h \
/usr/bin/moc
/usr/bin/moc $(DEFINES) $(INCPATH) console/console.h -o moc_console.cpp
+moc_restore.cpp: ui_brestore.h \
+ restore/restore.h \
+ /usr/bin/moc
+ /usr/bin/moc $(DEFINES) $(INCPATH) restore/restore.h -o moc_restore.cpp
+
compiler_rcc_make_all: qrc_main.cpp
compiler_rcc_clean:
-$(DEL_FILE) qrc_main.cpp
-$(DEL_FILE) qmake_image_collection.cpp
compiler_moc_source_make_all:
compiler_moc_source_clean:
-compiler_uic_make_all: ui_main.h ui_label.h ui_console.h
+compiler_uic_make_all: ui_main.h ui_label.h ui_console.h ui_brestore.h
compiler_uic_clean:
- -$(DEL_FILE) ui_main.h ui_label.h ui_console.h
+ -$(DEL_FILE) ui_main.h ui_label.h ui_console.h ui_brestore.h
ui_main.h: main.ui
/usr/bin/uic main.ui -o ui_main.h
ui_console.h: console/console.ui
/usr/bin/uic console/console.ui -o ui_console.h
+ui_brestore.h: restore/brestore.ui
+ /usr/bin/uic restore/brestore.ui -o ui_brestore.h
+
compiler_clean: compiler_moc_header_clean compiler_rcc_clean compiler_image_collection_clean compiler_moc_source_clean compiler_uic_clean
####### Compile
mainwin.h \
ui_main.h \
bat_conf.h \
- console/console.h
+ console/console.h \
+ ui_console.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o console.o console/console.cpp
+brestore.o: restore/brestore.cpp bat.h \
+ mainwin.h \
+ ui_main.h \
+ bat_conf.h \
+ restore/restore.h \
+ ui_brestore.h
+ $(CXX) -c $(CXXFLAGS) $(INCPATH) -o brestore.o restore/brestore.cpp
+
moc_mainwin.o: moc_mainwin.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_mainwin.o moc_mainwin.cpp
moc_console.o: moc_console.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_console.o moc_console.cpp
+moc_restore.o: moc_restore.cpp
+ $(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_restore.o moc_restore.cpp
+
qrc_main.o: qrc_main.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o qrc_main.o qrc_main.cpp
TEMPLATE = app
TARGET = bat
DEPENDPATH += .
-INCLUDEPATH += . ./console
+INCLUDEPATH += . ./console ./restore
INCLUDEPATH += ..
LIBS += -L../lib
LIBS += -lbac
# Label dialog
FORMS += label.ui
FORMS += console/console.ui
+FORMS += restore/brestore.ui
HEADERS += mainwin.h bat.h bat_conf.h
HEADERS += console/console.h
SOURCES += console/authenticate.cpp console/console.cpp
+# Restore
+HEADERS += restore/restore.h
+SOURCES += restore/brestore.cpp
+
# Label dialog
#include <QAbstractEventDispatcher>
#include "bat.h"
#include "console.h"
+#include "restore.h"
Console::Console(QStackedWidget *parent)
{
m_cursor = new QTextCursor(m_textEdit->document());
mainWin->actionConnect->setIcon(QIcon(QString::fromUtf8("images/disconnected.png")));
+ bRestore *restore = new bRestore(parent);
+ restore->setupUi(restore);
+ parent->addWidget(restore);
/* Just take the first Director */
LockRes();
--- /dev/null
+/*
+ Bacula® - The Network Backup Solution
+
+ Copyright (C) 2000-2007 Free Software Foundation Europe e.V.
+
+ The main author of Bacula is Kern Sibbald, 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 John Walker.
+ The licensor of Bacula is the Free Software Foundation Europe
+ (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich,
+ Switzerland, email:ftf@fsfeurope.org.
+*/
+
+/*
+ * bRestore Class (Eric's brestore)
+ *
+ * Kern Sibbald, January MMVI
+ *
+ */
+
+#include <QAbstractEventDispatcher>
+#include "bat.h"
+#include "restore.h"
+
+bRestore::bRestore(QStackedWidget *parent)
+{
+ setupUi(this);
+ parent->addWidget(this);
+}
+
--- /dev/null
+<ui version="4.0" >
+ <class>bRestoreForm</class>
+ <widget class="QWidget" name="bRestoreForm" >
+ <property name="geometry" >
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>800</width>
+ <height>600</height>
+ </rect>
+ </property>
+ <property name="windowTitle" >
+ <string>brestore</string>
+ </property>
+ <widget class="QWidget" name="centralwidget" >
+ <property name="geometry" >
+ <rect>
+ <x>70</x>
+ <y>30</y>
+ <width>582</width>
+ <height>533</height>
+ </rect>
+ </property>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QComboBox" name="ClientList" />
+ </item>
+ <item>
+ <widget class="QComboBox" name="JobList" >
+ <property name="enabled" >
+ <bool>false</bool>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer>
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeType" >
+ <enum>QSizePolicy::Expanding</enum>
+ </property>
+ <property name="sizeHint" >
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QPushButton" name="pushButton_4" >
+ <property name="text" >
+ <string>Location</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLineEdit" name="lineEdit" />
+ </item>
+ </layout>
+ </item>
+ <item>
+ <widget class="QSplitter" name="splitter_2" >
+ <property name="orientation" >
+ <enum>Qt::Vertical</enum>
+ </property>
+ <widget class="QSplitter" name="splitter" >
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <widget class="QGroupBox" name="groupBox" >
+ <property name="sizePolicy" >
+ <sizepolicy>
+ <hsizetype>7</hsizetype>
+ <vsizetype>7</vsizetype>
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="title" >
+ <string>File list</string>
+ </property>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QTableWidget" name="FileList" >
+ <property name="sizePolicy" >
+ <sizepolicy>
+ <hsizetype>7</hsizetype>
+ <vsizetype>7</vsizetype>
+ <horstretch>5</horstretch>
+ <verstretch>5</verstretch>
+ </sizepolicy>
+ </property>
+ <column>
+ <property name="text" >
+ <string>Type</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>File Name</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Size</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Date</string>
+ </property>
+ </column>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ <widget class="QGroupBox" name="groupBox_2" >
+ <property name="sizePolicy" >
+ <sizepolicy>
+ <hsizetype>7</hsizetype>
+ <vsizetype>7</vsizetype>
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="title" >
+ <string>File revisions</string>
+ </property>
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>9</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QTableWidget" name="FileRevisions" >
+ <property name="sizePolicy" >
+ <sizepolicy>
+ <hsizetype>7</hsizetype>
+ <vsizetype>7</vsizetype>
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <column>
+ <property name="text" >
+ <string>InChanger</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Volume</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>JobId</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Size</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Date</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Chksum</string>
+ </property>
+ </column>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </widget>
+ <widget class="QWidget" name="layoutWidget_2" >
+ <layout class="QVBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <layout class="QHBoxLayout" >
+ <property name="margin" >
+ <number>0</number>
+ </property>
+ <property name="spacing" >
+ <number>6</number>
+ </property>
+ <item>
+ <widget class="QLabel" name="label" >
+ <property name="text" >
+ <string><html><head><meta name="qrichtext" content="1" /><style type="text/css">
+p, li { white-space: pre-wrap; }
+</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal; text-decoration:none;">
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Restore items list</span></p></body></html></string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer>
+ <property name="orientation" >
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" >
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QPushButton" name="pushButton" >
+ <property name="text" >
+ <string>Clear</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QPushButton" name="pushButton_2" >
+ <property name="text" >
+ <string>Estimate</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QPushButton" name="pushButton_3" >
+ <property name="text" >
+ <string>Restore</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ <item>
+ <widget class="QTableWidget" name="RestoreList" >
+ <property name="acceptDrops" >
+ <bool>true</bool>
+ </property>
+ <column>
+ <property name="text" >
+ <string>Type</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>FileName</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>JobId</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>FileIndex</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Nb Files</string>
+ </property>
+ </column>
+ <column>
+ <property name="text" >
+ <string>Size</string>
+ </property>
+ </column>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
--- /dev/null
+
+#ifndef _RESTORE_H_
+#define _RESTORE_H_
+
+#include <QtGui>
+#include "ui_brestore.h"
+
+class bRestore : public QWidget, public Ui::bRestoreForm
+{
+ Q_OBJECT
+
+public:
+ bRestore(QStackedWidget *parent);
+
+public slots:
+
+private:
+
+};
+
+#endif /* _RESTORE_H_ */