/gpump/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/gpump/trunk

« back to all changes in this revision

Viewing changes to src/app.js

  • Committer: Gustav Hartvigsson
  • Date: 2014-06-09 13:00:41 UTC
  • Revision ID: gustav.hartvigsson@gmail.com-20140609130041-mn6cn3ogqw22jsas
* made the functions look more alike...
  ie: more glib-ish...

Show diffs side-by-side

added added

removed removed

Lines of Context:
37
37
      return;
38
38
    }
39
39
    
40
 
    this._prepareWindow ();
41
 
    this._prepareAppMenu ();
42
 
    this._prepareHeaderBar ();
 
40
    this._prepare_window ();
 
41
    this._prepare_app_menu ();
 
42
    this._prepare_header_bar ();
43
43
    
44
44
    this.window.show_all ();
45
45
  },
48
48
   * This function is used to prepare the window, it also initializes and adds
49
49
   * the headerbar to it.
50
50
   */
51
 
  _prepareWindow: function () {
 
51
  _prepare_window: function () {
52
52
    this.window = new Gtk.ApplicationWindow ({
53
53
      application: this,
54
54
      type: Gtk.WindowType.TOPLEVEL,
81
81
  /**
82
82
   * This function is used to create the application menu.
83
83
   */
84
 
  _prepareAppMenu: function () {
 
84
  _prepare_app_menu: function () {
85
85
    let menu = new Gio.Menu ();
86
86
    let section = new Gio.Menu ();
87
87
    
107
107
   * This function is used to prepare the hearderbar by adding buttons and
108
108
   * assigning callback functions to them.
109
109
   */
110
 
  _prepareHeaderBar: function () {
 
110
  _prepare_header_bar: function () {
111
111
    this.headerbar.pack_start ((this.new_post_btn = new Gtk.Button ({
112
112
      image: (new Gtk.Image ({icon_name: 'text-editor-symbolic'})),
113
113
      tooltip_text: _('Create new post')