Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=frugal-tweak.git;a=commitdiff;h=8464c8df1e02fbdd35191476a50574f4356f3b86

commit 8464c8df1e02fbdd35191476a50574f4356f3b86
Author: bouleetbil <bouleet...@frogdev.info>
Date:   Sun Jan 9 21:45:10 2011 +0100

*mini pacman-g2 frontend draft

diff --git a/frugal-tweak-vala/Makefile b/frugal-tweak-vala/Makefile
index 68c1a7a..c14b585 100644
--- a/frugal-tweak-vala/Makefile
+++ b/frugal-tweak-vala/Makefile
@@ -12,7 +12,9 @@ DAEMONSOURCES = $(SOURCEDIR)/daemon.vala 
$(SOURCEDIR)/pacman.vala $(SOURCEDIR)/t
TERMINALSOURCES = $(SOURCEDIR)/terminal.vala $(SOURCEDIR)/mainwindow.vala
BROWSERSOURCES = $(SOURCEDIR)/browser.vala
PACMANUPDATESOURCES = $(SOURCEDIR)/Tree.vala $(SOURCEDIR)/Pacman-update.vala 
$(SOURCEDIR)/pacman.vala $(SOURCEDIR)/tools.vala \
-                                       $(SOURCEDIR)/configuration.vala 
$(SOURCEDIR)/EventGtk.vala $(SOURCEDIR)/GtkObj.vala
+                                       $(SOURCEDIR)/configuration.vala 
$(SOURCEDIR)/EventGtk.vala $(SOURCEDIR)/GtkObj.vala $(SOURCEDIR)/Module.vala
+MINIPACMAN = $(SOURCEDIR)/Tree.vala $(SOURCEDIR)/mini-pacman-g2.vala 
$(SOURCEDIR)/pacman.vala $(SOURCEDIR)/tools.vala \
+                                       $(SOURCEDIR)/configuration.vala 
$(SOURCEDIR)/EventGtk.vala $(SOURCEDIR)/GtkObj.vala $(SOURCEDIR)/Module.vala
HOSTNAME = $(SOURCEDIR)/tools.vala $(SOURCEDIR)/FixHostname.vala 
$(SOURCEDIR)/configuration.vala
READLOG = $(SOURCEDIR)/tools.vala $(SOURCEDIR)/configuration.vala 
$(SOURCEDIR)/frugallog.vala $(SOURCEDIR)/EventGtk.vala \
$(SOURCEDIR)/GtkObj.vala
@@ -29,7 +31,7 @@ endif

VALAC = valac

-all: daemon terminal browser frugalwaretweak pacmanupdate
+all: daemon terminal browser frugalwaretweak pacmanupdate frugallog minipacman 
hostname

frugalwaretweak:
$(VALAC)  --Xcc="-Wl,--export-dynamic" --save-temps --define=$(DEBUGFLAG) --pkg 
gio-2.0 --pkg gtk+-2.0 --pkg gmodule-2.0 --pkg pacman  --pkg unique-1.0 --pkg 
libnotify \
@@ -38,10 +40,15 @@ frugalwaretweak:
$(FRUGALTWEAKSOURCES) -o frugalware-tweak2

pacmanupdate:
-       $(VALAC) --save-temps --define=$(DEBUGFLAG) --pkg gio-2.0 --pkg 
gtk+-2.0 --pkg gmodule-2.0  --pkg pacman \
-       --pkg posix  --thread  \
+       $(VALAC) --Xcc="-Wl,--export-dynamic"  --save-temps 
--define=$(DEBUGFLAG) --pkg gio-2.0 --pkg gtk+-2.0 --pkg gmodule-2.0  --pkg 
pacman \
+       --pkg posix  --pkg libxml-2.0 --thread  \
$(PACMANUPDATESOURCES) -o frugalware-tweak-pacman-update

+minipacman:
+       $(VALAC) --Xcc="-Wl,--export-dynamic" --save-temps 
--define=$(DEBUGFLAG) --pkg gio-2.0 --pkg gtk+-2.0 --pkg gmodule-2.0  --pkg 
pacman \
+       --pkg posix  --thread  --pkg libxml-2.0 \
+       $(MINIPACMAN) -o frugalware-tweak-pacman-g2
+
daemon:
$(VALAC) --save-temps --define=$(DEBUGFLAG) --pkg pacman --pkg gio-2.0 --pkg 
posix  --thread  $(DAEMONSOURCES) -o frugalware-tweak-daemon

@@ -74,6 +81,7 @@ install:
mkdir -p $(DESTDIR)/usr/share/frugalware-tweak/UI/
cp frugalware-tweak-log $(DESTDIR)/usr/bin/
cp DATA/01.readlog.xml $(DESTDIR)/usr/share/frugalware-tweak/plugins/
+       cp frugalware-tweak-pacman-g2 $(DESTDIR)/usr/bin/
cp frugalware-tweak-browser $(DESTDIR)/usr/bin/
cp frugalware-tweak-terminal $(DESTDIR)/usr/bin/
cp frugalware-tweak-daemon $(DESTDIR)/usr/bin/
@@ -99,6 +107,7 @@ install:

clean:
@rm src/*.c
+       @rm frugalware-tweak-pacman-g2
@rm frugalware-tweak-log
@rm frugalware-tweak-hostname
@rm frugalware-tweak-terminal
diff --git a/frugal-tweak-vala/UI/MainUI.ui b/frugal-tweak-vala/UI/MainUI.ui
index b799628..54388b8 100644
--- a/frugal-tweak-vala/UI/MainUI.ui
+++ b/frugal-tweak-vala/UI/MainUI.ui
@@ -477,4 +477,72 @@
</object>
</child>
</object>
+  <object class="GtkWindow" id="window_pacman">
+    <property name="width_request">400</property>
+    <property name="height_request">350</property>
+    <property name="title" translatable="yes">pacman-g2</property>
+    <property name="resizable">False</property>
+    <child>
+      <object class="GtkVBox" id="vbox5">
+        <property name="visible">True</property>
+        <property name="orientation">vertical</property>
+        <child>
+          <object class="GtkHBox" id="hbox8">
+            <property name="visible">True</property>
+            <child>
+              <object class="GtkComboBox" id="combobox1">
+                <property name="visible">True</property>
+              </object>
+              <packing>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkEntry" id="entry1">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="invisible_char">&#x2022;</property>
+              </object>
+              <packing>
+                <property name="position">1</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="button2">
+                <property name="label" translatable="yes">Search</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+              </object>
+              <packing>
+                <property name="position">2</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="position">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkScrolledWindow" id="scrolledwindow6">
+            <property name="width_request">400</property>
+            <property name="height_request">300</property>
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hscrollbar_policy">automatic</property>
+            <property name="vscrollbar_policy">automatic</property>
+            <child>
+              <object class="GtkTreeView" id="tree_package">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="position">1</property>
+          </packing>
+        </child>
+      </object>
+    </child>
+  </object>
</interface>
diff --git a/frugal-tweak-vala/src/Pacman-update.vala 
b/frugal-tweak-vala/src/Pacman-update.vala
index 1eeff47..9a19068 100644
--- a/frugal-tweak-vala/src/Pacman-update.vala
+++ b/frugal-tweak-vala/src/Pacman-update.vala
@@ -22,17 +22,8 @@ using Tree;

int main (string[] args) {
Gtk.init (ref args);
-/*
-       var window = new Window ();
-       window.title = "Update packages";
-       window.set_default_size (400, 300);
-       window.position = WindowPosition.CENTER;
-       window.destroy.connect (Gtk.main_quit);
-
-       //added treeview for modules
-       var view = new TreeView ();*/
var builder = new Builder ();
-        builder.add_from_file ("/usr/share/frugalware-tweak/UI//MainUI.ui");
+        builder.add_from_file ("/usr/share/frugalware-tweak/UI/MainUI.ui");
EventGtk event = new EventGtk();
builder.connect_signals (event);
var window = builder.get_object ("windowupd") as Window;
diff --git a/frugal-tweak-vala/src/mini-pacman-g2.vala 
b/frugal-tweak-vala/src/mini-pacman-g2.vala
new file mode 100644
index 0000000..506e2bd
--- /dev/null
+++ b/frugal-tweak-vala/src/mini-pacman-g2.vala
@@ -0,0 +1,37 @@
+/*
+ *
+ * (C) 2010 bouleetbil <bouleet...@frogdev.info>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * 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
+ */
+
+using Gtk;
+using Tree;
+
+int main (string[] args) {
+       Gtk.init (ref args);
+
+        var builder = new Builder ();
+        builder.add_from_file ("/usr/share/frugalware-tweak/UI/MainUI.ui");
+        EventGtk event = new EventGtk();
+       builder.connect_signals (event);
+        var window = builder.get_object ("window_pacman") as Window;
+       window.destroy.connect (Gtk.main_quit);
+
+       window.show_all ();
+
+    Gtk.main ();
+    return 0;
+}
_______________________________________________
Frugalware-git mailing list
Frugalware-git@frugalware.org
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to