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0LuS/hYq5ZiebuGuPI4V/FW5AG7mAormmExPt2qRrZkoU42qgVOm86NAGKfMSwUug/LbN5CQtClpcm9BmYqlzEoE64W9QMNNEIq4ISofe4JmZ3URACfQPGmbyEvFR+ZrJTQToolGt++cQEf+jfJ3E4A2QqmbyEvFjyzdRBPSgb4/eYo7U8h0pgl5BugevxkPcDjiXbyQC6qCGo/u+A9I1ODcexnqVbxiof98yk2zaSB/UeI4htfEwxq98CTgANZdlM0XCFjaeFxjbePCF5ds0k7sI0s4H9hgTPtX0KShFd7BurkjY/MtXE4KUWDb4RzYefqcvX4IvQflLPb2M2YZHCG46UPl2zO0nJtBB1CtUvmOv+LcYo8ajxSWlpmwufzGJNtGFoIlA4mnGfwKqntQNTyQmDFuqUtKE2MHCVgb987qZZismVkvVudDb0OXSgirontfHiu6Ing3PTiyyAipBbUKbkfSrapjf57nEgroP9Opn89230N8rl/sGT3O2j4xqmMMAAAAASUVORK5CYII='], colorList: ['#FDD','#FDF','#EDF','#DEF','#DFF','#CFC','#EFC','#FED','#FFF','#444'], getElementPosition: function (elem){
  • /*
     * @title htmlpainter
     * @description my bookmarklet
     * @include http://*
     * @license MIT License
     * @require 
     */
    
    
    var __nona_paint = {
    dragging: null,
    divlistcache: null,
    dropDst: null,
    backgroundColorBackup: null,
    onMouseDown : function(e) {
            var pos = __nona_paint.getElementPosition(this);
    	offsetX = e.pageX - pos.left;
    	offsetY = e.pageY - pos.top;
    	__nona_paint.dragging = this.cloneNode(true);
        __nona_paint.dragging.id="__nona_paint_dragging";
    	document.body.appendChild(__nona_paint.dragging);
    	__nona_paint.dragging.style.position = 'absolute';
    	return false;
    },
    onMouseMove: function(e) {
       if (!__nona_paint.dragging) {
          return true;
       }
        if (!__nona_paint.divlistcache)
        {
           __nona_paint.divlistcache = document.all;
        }
        __nona_paint.dragging.style.left = (e.pageX - offsetX)+'px';
        __nona_paint.dragging.style.top = (e.pageY - offsetY)+'px';
        var size = 0;
        var currentDropDst = null;
        var objlist = __nona_paint.divlistcache;
        for (i = 0; i < objlist.length; i++) {
            if (objlist[i] == __nona_paint.dragging) continue;
            if (objlist[i].className != '__nona_paint')
            var dstPos = __nona_paint.getElementPosition(objlist[i]);
            if (!(e.pageY > dstPos.top
            && e.pageY < dstPos.top + parseInt(objlist[i].clientHeight) + 8))
            {
                continue;
            }
            if (!(e.pageX > dstPos.left
            && e.pageX < dstPos.left + parseInt(objlist[i].clientWidth)))
            {
                continue;
            }
            if (size == 0 || size > objlist[i].clientHeight * objlist[i].clientWidth)
            {
                size = objlist[i].clientHeight * objlist[i].clientWidth;
                currentDropDst = objlist[i];
            }
        }
        if (__nona_paint.dropDst != currentDropDst)
        {
            if (__nona_paint.dropDst)
            {
                __nona_paint.dropDst.style.backgroundColor = __nona_paint.backgroundColorBackup;
            }
            __nona_paint.backgroundColorBackup = currentDropDst.style.backgroundColor;
            if (currentDropDst)
            {
                currentDropDst.style.backgroundColor = __nona_paint.dragging.getAttribute('data-paint-color');
            }
            __nona_paint.dropDst = currentDropDst;
        }
    },
    onMouseUp: function(e) {
        if (!__nona_paint.dragging) {
            return true;
        }
        __nona_paint.dragging.parentNode.removeChild(__nona_paint.dragging);
        if (__nona_paint.dropDst)
        {
            if (__nona_paint.dragging.getAttribute('data-paint-color') == '#444')
            {
                __nona_paint.dropDst.style.display = 'none';
            }
            else
            {
                __nona_paint.dropDst.style.backgroundColor = __nona_paint.dragging.getAttribute('data-paint-color');
            }
        }
        __nona_paint.dropDst = null;
        __nona_paint.dragging = null;
        __nona_paint.divlistcache = null;
    },
    srcList: ['data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAadEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjExR/NCNwAAAkhJREFUWEfFlyEwREEYx18QBOGCIAiCIAiiIAiCIArCBUEQBEEQBDOCIFwQLgiiIAi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AAadEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjExR/NCNwAAAh1JREFUWEftlqFTAkEUhwkEg4FAIBgIBgPBYDAYCAaCwWAkEggGg8FgcIZgIBgMBoPBwB9gIBgMBAPBYDAYDAaCwWAwGPD73by7GT24WxYOxxl+M98w996+3eXevn2XW+hfaDgc5qENm2aar1h4Hz5BuoKSubIXixXgHQ5hCx7gA45gyYZlJxY5hyfI27PS0YABPMNeMDALMXkFvqBmpkjY9GZ0LuS/hYq5ZiebuGuPI4V/FW5AG7mAormmExPt2qRrZkoU42qgVOm86NAGKfMSwUug/LbN5CQtClpcm9BmYqlzEoE64W9QMNNEIq4ISofe4JmZ3URACfQPGmbyEvFR+ZrJTQToolGt++cQEf+jfJ3E4A2QqmbyEvFjyzdRBPSgb4/eYo7U8h0pgl5BugevxkPcDjiXbyQC6qCGo/u+A9I1ODcexnqVbxiof98yk2zaSB/UeI4htfEwxq98CTgANZdlM0XCFjaeFxjbePCF5ds0k7sI0s4H9hgTPtX0KShFd7BurkjY/MtXE4KUWDb4RzYefqcvX4IvQflLPb2M2YZHCG46UPl2zO0nJtBB1CtUvmOv+LcYo8ajxSWlpmwufzGJNtGFoIlA4mnGfwKqntQNTyQmDFuqUtKE2MHCVgb987qZZismVkvVudDb0OXSgirontfHiu6Ing3PTiyyAipBbUKbkfSrapjf57nEgroP9Opn89230N8rl/sGT3O2j4xqmMMAAAAASUVORK5CYII='],
    colorList: ['#FDD','#FDF','#EDF','#DEF','#DFF','#CFC','#EFC','#FED','#FFF','#444'],
    
    getElementPosition: function (elem){
      var position=elem.getBoundingClientRect();
      return {
        left:Math.round(window.document.body.scrollLeft + document.documentElement.scrollLeft + position.left),
        top:Math.round(window.document.body.scrollTop + document.documentElement.scrollTop + position.top)
      }
    }
    };
    
    setTimeout(function () {
       objlist = document.getElementsByTagName('IMG');
       document.onmousemove = __nona_paint.onMouseMove;
       document.onmouseup = __nona_paint.onMouseUp;
       var palette = document.createElement("div");
       palette.style.backgroundColor = 'gray';
       palette.style.position = 'fixed';
       palette.style.opacity = '0.8';
       palette.style.zIndex = 999;
       palette.style.height= '40px';
       palette.style.padding = '4px';
       palette.style.width = '340px';
       palette.style.backgroundColor = 'gray';
       palette.className = '__nona_paint';
       for (var i = 0; i < 10; i++)
       {
           var image = document.createElement("img");
           image.src=__nona_paint.srcList[i];
           image.setAttribute('data-paint-color', __nona_paint.colorList[i]);
           image.className = '__nona_paint';
           image.onmousedown = __nona_paint.onMouseDown;
           palette.appendChild(image);
       }
       document.body.insertBefore(palette, document.body.childNodes[0]);
    }, 0);
  • Permalink
    このページへの個別リンクです。
    RAW
    書かれたコードへの直接のリンクです。
    Packed
    文字列が圧縮された書かれたコードへのリンクです。
    Userscript
    Greasemonkey 等で利用する場合の .user.js へのリンクです。
    Loader
    @require やソースコードが長い場合に多段ロードする Loader コミのコードへのリンクです。
    Metadata
    コード中にコメントで @xxx と書かれたメタデータの JSON です。

History

  1. 2014/06/11 22:57:18 - 2014-06-11
  2. 2014/06/11 22:50:43 - 2014-06-11
  3. 2014/06/11 22:48:52 - 2014-06-11
  4. 2014/06/11 22:10:34 - 2014-06-11
  5. 2014/06/11 22:08:27 - 2014-06-11
  6. 2014/06/11 21:55:20 - 2014-06-11
  7. 2014/06/11 21:29:56 - 2014-06-11
  8. 2014/06/11 21:22:07 - 2014-06-11
  9. 2014/06/11 21:06:23 - 2014-06-11
  10. 2014/06/11 21:01:17 - 2014-06-11
  11. 2014/06/11 21:00:28 - 2014-06-11