Paste Storyboards from ClipBoard | More convenient way to search a shot .blend file.
This commit is contained in:
parent
29e0dc2501
commit
6d1898a4c9
1 changed files with 32 additions and 2 deletions
|
@ -2515,7 +2515,37 @@ def layer(win):
|
||||||
button=do,
|
button=do,
|
||||||
fill=False)
|
fill=False)
|
||||||
layer.stroke()
|
layer.stroke()
|
||||||
|
|
||||||
|
else:
|
||||||
|
# If there is no image to show we can put one. Using a clipboard.
|
||||||
|
|
||||||
|
def do():
|
||||||
|
clipboard = Gtk.Clipboard.get(Gdk.SELECTION_CLIPBOARD)
|
||||||
|
im = clipboard.wait_for_image()
|
||||||
|
if not im:
|
||||||
|
return
|
||||||
|
Px = im.get_width()
|
||||||
|
Py = im.get_height()
|
||||||
|
Pc = cairo.ImageSurface(cairo.FORMAT_ARGB32, Px, Py)
|
||||||
|
Pb = cairo.Context(Pc)
|
||||||
|
Gdk.cairo_set_source_pixbuf( Pb, im, 0, 0)
|
||||||
|
Pb.paint()
|
||||||
|
|
||||||
|
imageurl = win.project+"/rnd"+win.cur+"/"+win.current[shotis+"_active_folder"]+"/0001.png"
|
||||||
|
|
||||||
|
Pc.write_to_png(imageurl)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
UI_elements.roundrect(layer, win,
|
||||||
|
x+5+(width/2)-20,
|
||||||
|
y+win.scroll["script_shots"]+current_Y_shots-7+80,
|
||||||
|
40,
|
||||||
|
40,
|
||||||
|
10,
|
||||||
|
button=do,
|
||||||
|
icon="image_new")
|
||||||
|
|
||||||
|
|
||||||
current_Y_shots = current_Y_shots + 210
|
current_Y_shots = current_Y_shots + 210
|
||||||
|
|
||||||
|
@ -2993,7 +3023,7 @@ def layer(win):
|
||||||
|
|
||||||
studio_dialogs.file_select(win, shotis+"_blends", after, force=True,
|
studio_dialogs.file_select(win, shotis+"_blends", after, force=True,
|
||||||
IMAGE=False, BLEND=True, VIDEO=False, FILE=False, CHR=False, VEH=False,
|
IMAGE=False, BLEND=True, VIDEO=False, FILE=False, CHR=False, VEH=False,
|
||||||
LOC=False, OBJ=False, RND=True, FOLDER=False, SEARCH=scene)
|
LOC=False, OBJ=False, RND=True, FOLDER=False, SEARCH=scene+" ")
|
||||||
|
|
||||||
UI_elements.roundrect(layer, win,
|
UI_elements.roundrect(layer, win,
|
||||||
x+tileX,
|
x+tileX,
|
||||||
|
|
Loading…
Add table
Reference in a new issue