<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Using undomanager in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197160#M18280</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;While this is possible (see attached) is there a particular reason why you wanted everything in a single file? This thread from a stack overflow user asks a similar question and there are some good replies. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://stackoverflow.com/questions/9322878/questions-about-dojo-modules-from-dojo-newb" title="http://stackoverflow.com/questions/9322878/questions-about-dojo-modules-from-dojo-newb"&gt;javascript - Questions about Dojo modules from Dojo newb? - Stack Overflow&lt;/A&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There's also some good info in the JSAPI help on creating modules: &lt;A href="https://developers.arcgis.com/javascript/jstutorials/intro_javascript_classes.html" title="https://developers.arcgis.com/javascript/jstutorials/intro_javascript_classes.html"&gt;Tutorials | ArcGIS API for JavaScript&lt;/A&gt; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 12 Sep 2014 17:45:34 GMT</pubDate>
    <dc:creator>KellyHutchins</dc:creator>
    <dc:date>2014-09-12T17:45:34Z</dc:date>
    <item>
      <title>Using undomanager</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197158#M18278</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey everybody,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was thinking about implementing the undomanager in my map to remove or re-add graphics.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When looking at the example page I found this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/jssamples/graphics_undoredo.html" title="https://developers.arcgis.com/javascript/jssamples/graphics_undoredo.html"&gt;Graphics with undo redo | ArcGIS API for JavaScript&lt;/A&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am able to get it to work, but I don't want to load an outside module, like they use the customoperation Does anyone have an example where all the code is within the application?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tim&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2014 14:38:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197158#M18278</guid>
      <dc:creator>TimWitt2</dc:creator>
      <dc:date>2014-09-12T14:38:10Z</dc:date>
    </item>
    <item>
      <title>Re: Using undomanager</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197159#M18279</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you download the sample, the code for the module is included with it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="javascript" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_14105436640117631 jive_text_macro" jivemacro_uid="_14105436640117631"&gt;
&lt;P&gt;define([&lt;/P&gt;
&lt;P&gt;&amp;nbsp; "dojo/_base/declare", "esri/OperationBase", "esri/toolbars/navigation"&lt;/P&gt;
&lt;P&gt;&amp;nbsp; ], function(declare, OperationBase, Navigation) {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var customOp = {};&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; customOp.Add = declare(OperationBase, {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; label: "Add Graphic",&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; constructor: function ( /*graphicsLayer, addedGraphic*/ params) {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; params = params || {};&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!params.graphicsLayer) {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; console.error("graphicsLayer is not provided");&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.graphicsLayer = params.graphicsLayer;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!params.addedGraphic) {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; console.error("no graphics provided");&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this._addedGraphic = params.addedGraphic;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; },&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; performUndo: function () {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.graphicsLayer.remove(this._addedGraphic);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; },&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; performRedo: function () {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.graphicsLayer.add(this._addedGraphic);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;
&lt;P&gt;&amp;nbsp; });&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; return customOp;&lt;/P&gt;
&lt;P&gt;});&lt;/P&gt;
&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2014 17:41:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197159#M18279</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2014-09-12T17:41:08Z</dc:date>
    </item>
    <item>
      <title>Re: Using undomanager</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197160#M18280</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;While this is possible (see attached) is there a particular reason why you wanted everything in a single file? This thread from a stack overflow user asks a similar question and there are some good replies. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://stackoverflow.com/questions/9322878/questions-about-dojo-modules-from-dojo-newb" title="http://stackoverflow.com/questions/9322878/questions-about-dojo-modules-from-dojo-newb"&gt;javascript - Questions about Dojo modules from Dojo newb? - Stack Overflow&lt;/A&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There's also some good info in the JSAPI help on creating modules: &lt;A href="https://developers.arcgis.com/javascript/jstutorials/intro_javascript_classes.html" title="https://developers.arcgis.com/javascript/jstutorials/intro_javascript_classes.html"&gt;Tutorials | ArcGIS API for JavaScript&lt;/A&gt; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2014 17:45:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197160#M18280</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2014-09-12T17:45:34Z</dc:date>
    </item>
    <item>
      <title>Re: Using undomanager</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197161#M18281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Jake, would I be able to just include that in my application or is there another step I would have to do?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2014 17:46:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197161#M18281</guid>
      <dc:creator>TimWitt2</dc:creator>
      <dc:date>2014-09-12T17:46:15Z</dc:date>
    </item>
    <item>
      <title>Re: Using undomanager</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197162#M18282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey Kelly,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for the quick reply and thanks for the zip file and the helpful links.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At the moment I am working on an &lt;A href="http://jsfiddle.net/timw1984/zc19huhu/embedded/result/"&gt;Advanced Draw Widget&lt;/A&gt; and wanted to include the redo/undo function. Instead of explaining the user how to install modules, I wanted a one-stop shop &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt; That is why I wanted to include everything in one file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Btw. let me know what you think of the widget &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/wink.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tim&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2014 17:54:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/using-undomanager/m-p/197162#M18282</guid>
      <dc:creator>TimWitt2</dc:creator>
      <dc:date>2014-09-12T17:54:51Z</dc:date>
    </item>
  </channel>
</rss>

