Skip to content

Commit

Permalink
Remove print statements
Browse files Browse the repository at this point in the history
  • Loading branch information
maoschanz committed Jul 28, 2019
1 parent fcdb9bd commit ae19d72
Show file tree
Hide file tree
Showing 6 changed files with 0 additions and 26 deletions.
5 changes: 0 additions & 5 deletions src/image.py
Original file line number Diff line number Diff line change
Expand Up @@ -287,11 +287,6 @@ def update_history_actions_labels(self):
self.window.update_history_actions_labels(undo_label, redo_label)

def add_operation_to_history(self, operation):
# print('add_operation_to_history')
# print(operation['tool_id'])
# if operation['tool_id'] == 'select':
# print(operation['operation_type'])
# print('-----------------------------------')
self._is_saved = False
self.undo_history.append(operation)
self.update_history_sensitivity()
Expand Down
4 changes: 0 additions & 4 deletions src/selection_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ def __init__(self, image):
self.l_popover = Gtk.Popover.new_from_model(self.image.window.notebook, menu_l)

def init_pixbuf(self):
print('⇒ init pixbuf')
self.selection_pixbuf = GdkPixbuf.Pixbuf.new(GdkPixbuf.Colorspace.RGB, True, 8, 1, 1)

self.set_coords(True, 0, 0)
Expand Down Expand Up @@ -83,7 +82,6 @@ def load_from_path(self, new_path):
print(self.selection_x, xmin, self.selection_y, ymin)

# Actually store the pixbuf
print('⇒ load pixbuf')
self.selection_pixbuf = Gdk.pixbuf_get_from_surface(surface, \
int(xmin), int(ymin), int(xmax - xmin), int(ymax - ymin))
# XXX PAS_SOUHAITABLE ?? passer par set_pixbuf est-il plus sain ?
Expand All @@ -100,15 +98,13 @@ def set_pixbuf(self, pixbuf, use_import_param, is_imported_data):
if use_import_param:
self.is_imported_data = is_imported_data
self.temp_path = None
print('⇒ set pixbuf')
self.selection_pixbuf = pixbuf
self._create_path_from_pixbuf(not self.is_imported_data)

def get_pixbuf(self):
return self.selection_pixbuf

def reset(self):
print('⇒ reset pixbuf')
self.selection_pixbuf = None
self.selection_path = None
self.set_coords(True, 0, 0)
Expand Down
1 change: 0 additions & 1 deletion src/tools/classic_tools/tool_paint.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ def get_edition_status(self):
return self.label

def on_press_on_area(self, area, event, surface, tool_width, left_color, right_color, event_x, event_y):
print("press")
if event.button == 1:
self.new_color = left_color
if event.button == 3:
Expand Down
2 changes: 0 additions & 2 deletions src/tools/selection_tools/tool_select.py
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,6 @@ def op_delete(self, operation):
self.get_selection().delete_temp()

def op_drag(self, operation):
# print('drag to : ', operation['pixb_x'], operation['pixb_y'])
self.get_selection().set_coords(False, \
operation['pixb_x'], operation['pixb_y'])
self.non_destructive_show_modif()
Expand Down Expand Up @@ -364,7 +363,6 @@ def do_tool_operation(self, operation):
if operation['tool_id'] != self.id:
return
self.restore_pixbuf()
print(operation['operation_type'])
if operation['operation_type'] == 'op-delete':
# Opération instantanée (sans preview), correspondant à une action
# de type "clic-droit > couper" ou "clic-droit > supprimer".
Expand Down
11 changes: 0 additions & 11 deletions src/utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@ def utilities_get_magic_path(surface, x, y, window, coef):

(first_x, first_y) = (x, y)

print(str(x) + ' ' + str(y))

# 0 1 2
# 7 3
# 6 5 4
Expand Down Expand Up @@ -86,24 +84,16 @@ def utilities_get_magic_path(surface, x, y, window, coef):
x = new_x+x_shift[direction]
y = new_y+y_shift[direction]
end_circle = True
else:
print('cas emmerdant')
j = j+1

direction = (direction+4) % 8
# print('direction:')
# print(direction)
if (new_x != -10):
cairo_context.line_to(x, y)
# else:
# print('TENTATIVE ABUSIVE D\'AJOUT')
# should_stop = True

if (i > 10) and (first_x-5 < x < first_x+5) and (first_y-5 < y < first_y+5):
should_stop = True

i = i + 1
# print('----------')

if i == 2000:
dialog, continue_id = launch_infinite_loop_dialog(window)
Expand All @@ -115,7 +105,6 @@ def utilities_get_magic_path(surface, x, y, window, coef):
return

cairo_context.close_path()
# print('i: ' + str(i))
return cairo_context.copy_path()

def launch_infinite_loop_dialog(window):
Expand Down
3 changes: 0 additions & 3 deletions src/window.py
Original file line number Diff line number Diff line change
Expand Up @@ -976,9 +976,6 @@ def action_rebuild(self, *args): # XXX image method ?
h = self.get_active_image().undo_history.copy()
self.get_active_image().undo_history = []
for op in h:
# print()
# print(op)
# print()
self.tools[op['tool_id']].apply_operation(op)
self.get_active_image().update()
self.get_active_image().update_history_sensitivity()
Expand Down

0 comments on commit ae19d72

Please sign in to comment.