title: Jira Gadget in Confluence config issue
body: <p>I have a Jira gadget that I wrote that I would like to be used from confluence. I have Jira and Confluence running locally on my machine. I have my gadget installed to my jira instance and I have both instances linked with full trust as application links. I have installed my gadget in confluence in the External Gadgets section in the Admin. I then created a simple page and added my gadget via select macro. When I click on my gadget, I'm having issues with the display of my configuration screen. It seems like its missing my i18n resource because I am seeing this for a label gadget.common.project.label. Also the iframe isn't expanding to contain all of my configs.</p>
  
  <p>Here is what my gadget looks like in confluence:</p>
  
  <p><img src="https://i.stack.imgur.com/pZw8w.png" alt="enter image description here"></p>
  
  <p>Here is the head section of my gadgets gadget.xml:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8" ?&gt;
  &lt;Module&gt;
  &lt;ModulePrefs title="__MSG_gadget.title__" 
               directory_title="__MSG_gadget.title__"
               description="__MSG_gadget.description__"
               author="__MSG_gadget.author__"
               thumbnail='#staticResourceUrl("TechnicalDebtTracker:TechnicalDebtTracker-resources", "thumbnail.png")'&gt;
      &lt;Optional feature="gadget-directory"&gt;
          &lt;Param name="categories"&gt;
              . JIRA
          &lt;/Param&gt;
      &lt;/Optional&gt;
      &lt;Optional feature="atlassian.util"/&gt;
      &lt;Optional feature="auth-refresh"/&gt;
      &lt;Require feature="setprefs" /&gt;
      &lt;Require feature="dynamic-height"/&gt;
      &lt;Require feature="settitle"/&gt;
      &lt;Require feature="views"/&gt;
      &lt;Require feature="oauthpopup"/&gt;
      #oauth
      #supportedLocales("gadget.common,gadget.user.activity")
      &lt;Locale messages="__ATLASSIAN_BASE_URL__/download/resources/TechnicalDebtTracker/i18n/ALL_ALL.xml"/&gt;
  &lt;/ModulePrefs&gt;
  &lt;UserPref name="isConfigured" datatype="hidden" default_value="false" /&gt;
  &lt;UserPref name="project" datatype="hidden" required="true" /&gt;
  &lt;UserPref name="methodology_type" datatype="hidden" required="true" default_value="scrum" /&gt;
  &lt;UserPref name="warning_threshold" datatype="hidden" required="true" default_value="10" /&gt;
  &lt;UserPref name="critical_threshold" datatype="hidden" required="true" default_value="20" /&gt;
  &lt;UserPref name="paid_down_period" datatype="hidden" required="true" default_value="90" /&gt;
  &lt;UserPref name="normal_color" datatype="hidden" required="true" default_value="#61F553" /&gt;
  &lt;UserPref name="warning_color" datatype="hidden" required="true" default_value="#FFFA66" /&gt;
  &lt;UserPref name="critical_color" datatype="hidden" required="true" default_value="#FF7A66" /&gt;
  &lt;UserPref name="refresh" datatype="hidden" default_value="false" /&gt;
  &lt;Content type="html"&gt;
      &lt;![CDATA[
          #requireResource("com.atlassian.gadgets.publisher:ajs-gadgets")
          #requireResource("com.atlassian.jira.gadgets:g-filter-results")
          #requireResource("TechnicalDebtTracker:TechnicalDebtTracker-resources")
          #includeResources()
  
  (function () 
          {       
          var gadget = AJS.Gadget({
              baseUrl: "__ATLASSIAN_BASE_URL__",
              useOauth: "/rest/gadget/1.0/currentUser",
              config: {
                  descriptor: function(args) {
                      var gadget = this;
  
                      var projectPicker = AJS.gadget.fields.projectPicker(gadget, "project", args.projectOptions);
                      return {
                          fields: [
                              projectPicker,
                              {
                                  id: "methodology_type-id",
                                  userpref: "methodology_type",
                                  label: "__MSG_gadget.config.SetMethodology__",
                                  description: "",
                                  type: "select",
                                  selected: gadget.getPref("methodology_type"),
                                  options: [
                                              {
                                                  label:"Scrum",
                                                  value:"scrum"
                                              },
                                              {
                                                  label:"Kanban",
                                                  value:"kanban"
                                              }
                                           ]
                              },
                              {
                                  id: "warning_threshold-id",
                                  userpref: "warning_threshold",
                                  label: "__MSG_gadget.config.SetWarning__",
                                  description: "__MSG_gadget.config.InStoryPoints__",
                                  type: "text",
                                  value: gadget.getPref("warning_threshold")
                              },
                              {
                                  id: "critical_threshold-id",
                                  userpref: "critical_threshold",
                                  label: "__MSG_gadget.config.SetCritical__",
                                  description: "__MSG_gadget.config.InStoryPoints__",
                                  type: "text",
                                  value: gadget.getPref("critical_threshold")
                              },
                              {
                                  id: "paid_down_period-id",
                                  userpref: "paid_down_period",
                                  label: "__MSG_gadget.config.SetPaidDownPeriod__",
                                  description: "__MSG_gadget.config.InDays__",
                                  type: "text",
                                  value: gadget.getPref("paid_down_period")
                              },
                              {
                                  id: "normal_color-id",
                                  userpref: "normal_color",
                                  label: "__MSG_gadget.config.SetNormalColor__",
                                  description: "__MSG_gadget.config.HexCode__",
                                  type: "text",
                                  value: gadget.getPref("normal_color")
                              },
                              {
                                  id: "warning_color-id",
                                  userpref: "warning_color",
                                  label: "__MSG_gadget.config.SetWarningColor__",
                                  description: "__MSG_gadget.config.HexCode__",
                                  type: "text",
                                  value: gadget.getPref("warning_color")
                              },
                              {
                                  id: "critical_color-id",
                                  userpref: "critical_color",
                                  label: "__MSG_gadget.config.SetCriticalColor__",
                                  description: "__MSG_gadget.config.HexCode__",
                                  type: "text",
                                  value: gadget.getPref("critical_color")
                              },
                              AJS.gadget.fields.nowConfigured()
                          ]
                      };
                  },
                  args: function()
                  {
                      return [
                          {
                              key: "projectOptions",
                              ajaxOptions:  "/rest/gadget/1.0/filtersAndProjects?showFilters=false"
                          },
                      ];
                  }()
              },
  </code></pre>