Ignore:
Timestamp:
07/04/19 18:54:23 (5 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
python3
Phase:
public
Message:

Removed Gtk 2/3 constant definitions (re #347)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/gui/bugreport.py

    r996 r999  
    2424                                              xstr("bugreport_title"),
    2525                                              gui.mainWindow,
    26                                               DIALOG_MODAL)
     26                                              Gtk.DialogFlags.MODAL)
    2727
    28         self.add_button(xstr("button_cancel"), RESPONSETYPE_REJECT)
    29         self._sendButton = self.add_button(xstr("button_send"), RESPONSETYPE_ACCEPT)
     28        self.add_button(xstr("button_cancel"), Gtk.ResponseType.REJECT)
     29        self._sendButton = self.add_button(xstr("button_send"), Gtk.ResponseType.ACCEPT)
    3030        self._sendButton.set_can_default(True)
    3131        self._gui = gui
     
    6464        self._description = description = Gtk.TextView()
    6565        description.set_tooltip_text(xstr("bugreport_description_tooltip"))
    66         description.set_wrap_mode(WRAP_WORD)
     66        description.set_wrap_mode(Gtk.WrapMode.WORD)
    6767        label.set_mnemonic_widget(description)
    6868
     
    7070        scrolledWindow.add(description)
    7171        scrolledWindow.set_size_request(-1, 200)
    72         scrolledWindow.set_policy(POLICY_AUTOMATIC, POLICY_AUTOMATIC)
    73         scrolledWindow.set_shadow_type(SHADOW_IN)
     72        scrolledWindow.set_policy(Gtk.PolicyType.AUTOMATIC,
     73                                  Gtk.PolicyType.AUTOMATIC)
     74        scrolledWindow.set_shadow_type(Gtk.ShadowType.IN)
    7475
    7576        alignment = Gtk.Alignment(xalign = 0.5, yalign = 0.0, xscale = 1.0, yscale = 1.0)
     
    105106        response = super(BugReportDialog, self).run()
    106107
    107         print("response", response, RESPONSETYPE_ACCEPT)
    108         if response==RESPONSETYPE_ACCEPT:
     108        print("response", response, Gtk.ResponseType.ACCEPT)
     109        if response==Gtk.ResponseType.ACCEPT:
    109110            self._send()
    110111        else:
Note: See TracChangeset for help on using the changeset viewer.