/*
 * DO NOT EDIT THIS FILE - it is generated by Glade.
 */

#ifdef HAVE_CONFIG_H
#  include <config.h>
#endif

#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <string.h>
#include <stdio.h>

#include <gdk/gdkkeysyms.h>
#include <gtk/gtk.h>

#include "callbacks.h"
#include "interface.h"
#include "support.h"

#define GLADE_HOOKUP_OBJECT(component,widget,name) \
  g_object_set_data_full (G_OBJECT (component), name, \
    gtk_widget_ref (widget), (GDestroyNotify) gtk_widget_unref)

#define GLADE_HOOKUP_OBJECT_NO_REF(component,widget,name) \
  g_object_set_data (G_OBJECT (component), name, widget)

GtkWidget*
create_bebocd (void)
{
  GtkWidget *bebocd;
  GtkWidget *vbox1;
  GtkWidget *hbox2;
  GtkWidget *frame1;
  GtkWidget *label4;
  GtkWidget *label3;
  GtkWidget *vbox2;
  GtkWidget *button7;
  GtkWidget *image7;
  GtkWidget *hscale1;
  GtkWidget *hbox1;
  GtkWidget *button1;
  GtkWidget *image1;
  GtkWidget *button2;
  GtkWidget *image2;
  GtkWidget *button3;
  GtkWidget *image3;
  GtkWidget *button4;
  GtkWidget *image4;
  GtkWidget *button5;
  GtkWidget *image5;
  GtkWidget *button6;
  GtkWidget *image6;
  GtkWidget *combo1;
  GtkWidget *combo_entry1;

  bebocd = gtk_window_new (GTK_WINDOW_TOPLEVEL);
  gtk_window_set_title (GTK_WINDOW (bebocd), _("beboCD"));
  gtk_window_set_position (GTK_WINDOW (bebocd), GTK_WIN_POS_CENTER);
  gtk_window_set_default_size (GTK_WINDOW (bebocd), 250, 130);

  vbox1 = gtk_vbox_new (FALSE, 0);
  gtk_widget_show (vbox1);
  gtk_container_add (GTK_CONTAINER (bebocd), vbox1);

  hbox2 = gtk_hbox_new (FALSE, 0);
  gtk_widget_show (hbox2);
  gtk_box_pack_start (GTK_BOX (vbox1), hbox2, TRUE, TRUE, 2);

  frame1 = gtk_frame_new (NULL);
  gtk_widget_show (frame1);
  gtk_box_pack_start (GTK_BOX (hbox2), frame1, TRUE, TRUE, 2);

  label4 = gtk_label_new (_("BeboCD"));
  gtk_widget_show (label4);
  gtk_container_add (GTK_CONTAINER (frame1), label4);
  gtk_label_set_justify (GTK_LABEL (label4), GTK_JUSTIFY_LEFT);

  label3 = gtk_label_new ("");
  gtk_widget_show (label3);
  gtk_frame_set_label_widget (GTK_FRAME (frame1), label3);
  gtk_label_set_justify (GTK_LABEL (label3), GTK_JUSTIFY_LEFT);

  vbox2 = gtk_vbox_new (FALSE, 0);
  gtk_widget_show (vbox2);
  gtk_box_pack_start (GTK_BOX (hbox2), vbox2, FALSE, TRUE, 2);

  button7 = gtk_button_new ();
  gtk_widget_show (button7);
  gtk_box_pack_end (GTK_BOX (vbox2), button7, FALSE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (button7, GTK_CAN_FOCUS);

  image7 = create_pixmap (bebocd, "bebocd.xpm");
  gtk_widget_show (image7);
  gtk_container_add (GTK_CONTAINER (button7), image7);

  hscale1 = gtk_hscale_new (GTK_ADJUSTMENT (gtk_adjustment_new (1, 1, 255, 1, 0, 0)));
  gtk_widget_show (hscale1);
  gtk_box_pack_start (GTK_BOX (vbox2), hscale1, TRUE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (hscale1, GTK_CAN_FOCUS);
  gtk_scale_set_draw_value (GTK_SCALE (hscale1), FALSE);

  hbox1 = gtk_hbox_new (TRUE, 0);
  gtk_widget_show (hbox1);
  gtk_box_pack_start (GTK_BOX (vbox1), hbox1, FALSE, FALSE, 0);

  button1 = gtk_button_new ();
  gtk_widget_show (button1);
  gtk_box_pack_start (GTK_BOX (hbox1), button1, FALSE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (button1, GTK_CAN_FOCUS);

  image1 = create_pixmap (bebocd, "fleft.xpm");
  gtk_widget_show (image1);
  gtk_container_add (GTK_CONTAINER (button1), image1);

  button2 = gtk_button_new ();
  gtk_widget_show (button2);
  gtk_box_pack_start (GTK_BOX (hbox1), button2, FALSE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (button2, GTK_CAN_FOCUS);

  image2 = create_pixmap (bebocd, "pause.xpm");
  gtk_widget_show (image2);
  gtk_container_add (GTK_CONTAINER (button2), image2);

  button3 = gtk_button_new ();
  gtk_widget_show (button3);
  gtk_box_pack_start (GTK_BOX (hbox1), button3, FALSE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (button3, GTK_CAN_FOCUS);

  image3 = create_pixmap (bebocd, "play.xpm");
  gtk_widget_show (image3);
  gtk_container_add (GTK_CONTAINER (button3), image3);

  button4 = gtk_button_new ();
  gtk_widget_show (button4);
  gtk_box_pack_start (GTK_BOX (hbox1), button4, FALSE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (button4, GTK_CAN_FOCUS);

  image4 = create_pixmap (bebocd, "stop.xpm");
  gtk_widget_show (image4);
  gtk_container_add (GTK_CONTAINER (button4), image4);

  button5 = gtk_button_new ();
  gtk_widget_show (button5);
  gtk_box_pack_start (GTK_BOX (hbox1), button5, FALSE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (button5, GTK_CAN_FOCUS);

  image5 = create_pixmap (bebocd, "fright.xpm");
  gtk_widget_show (image5);
  gtk_container_add (GTK_CONTAINER (button5), image5);

  button6 = gtk_button_new ();
  gtk_widget_show (button6);
  gtk_box_pack_start (GTK_BOX (hbox1), button6, FALSE, TRUE, 0);
  GTK_WIDGET_UNSET_FLAGS (button6, GTK_CAN_FOCUS);

  image6 = create_pixmap (bebocd, "eject.xpm");
  gtk_widget_show (image6);
  gtk_container_add (GTK_CONTAINER (button6), image6);

  combo1 = gtk_combo_new ();
  g_object_set_data (G_OBJECT (GTK_COMBO (combo1)->popwin),
                     "GladeParentKey", combo1);
  gtk_widget_show (combo1);
  gtk_box_pack_start (GTK_BOX (vbox1), combo1, FALSE, FALSE, 0);

  combo_entry1 = GTK_COMBO (combo1)->entry;
  gtk_widget_show (combo_entry1);
  GTK_WIDGET_UNSET_FLAGS (combo_entry1, GTK_CAN_FOCUS);
  gtk_editable_set_editable (GTK_EDITABLE (combo_entry1), FALSE);

  g_signal_connect ((gpointer) bebocd, "delete_event",
                    G_CALLBACK (bebo_cd_quit),
                    NULL);
  g_signal_connect ((gpointer) button7, "clicked",
                    G_CALLBACK (bebo_show_aboutdlg),
                    NULL);
  g_signal_connect ((gpointer) hscale1, "value_changed",
                    G_CALLBACK (bebo_set_mixer),
                    NULL);
  g_signal_connect ((gpointer) button1, "clicked",
                    G_CALLBACK (bebo_prev_track),
                    NULL);
  g_signal_connect ((gpointer) button2, "clicked",
                    G_CALLBACK (bebo_pause_cd),
                    NULL);
  g_signal_connect ((gpointer) button3, "clicked",
                    G_CALLBACK (bebo_play_cd),
                    NULL);
  g_signal_connect ((gpointer) button4, "clicked",
                    G_CALLBACK (bebo_stop_cd),
                    NULL);
  g_signal_connect ((gpointer) button5, "clicked",
                    G_CALLBACK (bebo_next_track),
                    NULL);
  g_signal_connect ((gpointer) button6, "clicked",
                    G_CALLBACK (bebo_eject_cd),
                    NULL);
  g_signal_connect_after ((gpointer) combo_entry1, "changed",
                          G_CALLBACK (bebo_comboentry_activate),
                          NULL);

  /* Store pointers to all widgets, for use by lookup_widget(). */
  GLADE_HOOKUP_OBJECT_NO_REF (bebocd, bebocd, "bebocd");
  GLADE_HOOKUP_OBJECT (bebocd, vbox1, "vbox1");
  GLADE_HOOKUP_OBJECT (bebocd, hbox2, "hbox2");
  GLADE_HOOKUP_OBJECT (bebocd, frame1, "frame1");
  GLADE_HOOKUP_OBJECT (bebocd, label4, "label4");
  GLADE_HOOKUP_OBJECT (bebocd, label3, "label3");
  GLADE_HOOKUP_OBJECT (bebocd, vbox2, "vbox2");
  GLADE_HOOKUP_OBJECT (bebocd, button7, "button7");
  GLADE_HOOKUP_OBJECT (bebocd, image7, "image7");
  GLADE_HOOKUP_OBJECT (bebocd, hscale1, "hscale1");
  GLADE_HOOKUP_OBJECT (bebocd, hbox1, "hbox1");
  GLADE_HOOKUP_OBJECT (bebocd, button1, "button1");
  GLADE_HOOKUP_OBJECT (bebocd, image1, "image1");
  GLADE_HOOKUP_OBJECT (bebocd, button2, "button2");
  GLADE_HOOKUP_OBJECT (bebocd, image2, "image2");
  GLADE_HOOKUP_OBJECT (bebocd, button3, "button3");
  GLADE_HOOKUP_OBJECT (bebocd, image3, "image3");
  GLADE_HOOKUP_OBJECT (bebocd, button4, "button4");
  GLADE_HOOKUP_OBJECT (bebocd, image4, "image4");
  GLADE_HOOKUP_OBJECT (bebocd, button5, "button5");
  GLADE_HOOKUP_OBJECT (bebocd, image5, "image5");
  GLADE_HOOKUP_OBJECT (bebocd, button6, "button6");
  GLADE_HOOKUP_OBJECT (bebocd, image6, "image6");
  GLADE_HOOKUP_OBJECT (bebocd, combo1, "combo1");
  GLADE_HOOKUP_OBJECT (bebocd, combo_entry1, "combo_entry1");

  return bebocd;
}

GtkWidget*
create_dialog1 (void)
{
  GtkWidget *dialog1;
  GtkWidget *dialog_vbox1;
  GtkWidget *label5;
  GtkWidget *dialog_action_area1;
  GtkWidget *okbutton1;

  dialog1 = gtk_dialog_new ();
  gtk_window_set_title (GTK_WINDOW (dialog1), _("About"));
  gtk_window_set_position (GTK_WINDOW (dialog1), GTK_WIN_POS_CENTER);
  gtk_dialog_set_has_separator (GTK_DIALOG (dialog1), FALSE);

  dialog_vbox1 = GTK_DIALOG (dialog1)->vbox;
  gtk_widget_show (dialog_vbox1);

  label5 = gtk_label_new (_("\n beboCD \n GTK2 cdplayer by mironcho \n\n http://bebocd.sourceforge.net \n mironcho@users.sourceforge.net \n"));
  gtk_widget_show (label5);
  gtk_box_pack_start (GTK_BOX (dialog_vbox1), label5, TRUE, TRUE, 0);

  dialog_action_area1 = GTK_DIALOG (dialog1)->action_area;
  gtk_widget_show (dialog_action_area1);
  gtk_button_box_set_layout (GTK_BUTTON_BOX (dialog_action_area1), GTK_BUTTONBOX_END);

  okbutton1 = gtk_button_new_from_stock ("gtk-ok");
  gtk_widget_show (okbutton1);
  gtk_dialog_add_action_widget (GTK_DIALOG (dialog1), okbutton1, GTK_RESPONSE_OK);
  GTK_WIDGET_SET_FLAGS (okbutton1, GTK_CAN_DEFAULT);

  g_signal_connect ((gpointer) dialog1, "delete_event",
                    G_CALLBACK (bebo_hide_aboutdlg),
                    NULL);
  g_signal_connect ((gpointer) okbutton1, "clicked",
                    G_CALLBACK (bebo_hide_aboutdlg),
                    NULL);

  /* Store pointers to all widgets, for use by lookup_widget(). */
  GLADE_HOOKUP_OBJECT_NO_REF (dialog1, dialog1, "dialog1");
  GLADE_HOOKUP_OBJECT_NO_REF (dialog1, dialog_vbox1, "dialog_vbox1");
  GLADE_HOOKUP_OBJECT (dialog1, label5, "label5");
  GLADE_HOOKUP_OBJECT_NO_REF (dialog1, dialog_action_area1, "dialog_action_area1");
  GLADE_HOOKUP_OBJECT (dialog1, okbutton1, "okbutton1");

  return dialog1;
}

