<commit_before>// Google BSD license http://code.google.com/google_bsd_license.html
// Copyright 2013 Google Inc. <EMAIL>

(function(){

  QuerypointPanel.OnPanelOpen = {
    
    onClick: function(event) {
      var target = event.target;
      var className = target.classList.item(0);
      if (className) {
        var objMethod = className.split('_');
        var obj = objMethod[0];
        var method = objMethod[1];
        if (obj && method) {
          this[obj][method].call(this, event);  
        }  
      }
    },

    initialize: function(panel) {
      this.panel = panel;          // TODO: should be this._panel
      var onPanelOpen = document.querySelector('div.onPanelOpen');
      onPanelOpen.addEventListener('click', this.onClick.bind(this));
    },
    
    close: function() {
      var logView = document.querySelector('div.logView');
      logView.classList.remove('initialView');
    },

    open: function() {
      var logView = document.querySelector('div.logView');
      logView.classList.add('initialView');
    },

    // Functions wired to eg hint_overview
    hint: {
      overview: function() {
        this.panel.toggleHelp();
      },
      documentation: function() {
        window.open("http://google.github.com/qpp/documentation.html");
      },
      feedback: function() {
        window.open("https://github.com/google/qpp/issues/new");
      }
    },
    initialOptions: {
      justReload: function () {
        this.panel.project.reload();
        this.close();
      },
      reloadAndTrace: function() {
        var fileViewModel = this.panel.fileViewModels()[0];
        var tree = fileViewModel.treeRoot();
        var panel = this.panel;
        var project = panel.project;
        var queires = project.querypoints.possibleQueries().forEach(function(possibleQuery) {
          var query = possibleQuery.ifAvailableFor(tree, project);
          if (query) {
            var queryVM = new QuerypointPanel.QueryViewModel(query, panel);
            queryVM.activateQuery(fileViewModel);
          }
        });
        this.close();        
      },
      noReload: function() {
        this.close();
      }
    }
  }

}());<commit_msg>Remove reload-and-trace option from initial panel for now at least<commit_after>// Google BSD license http://code.google.com/google_bsd_license.html
// Copyright 2013 Google Inc. <EMAIL>

(function(){

  QuerypointPanel.OnPanelOpen = {
    
    onClick: function(event) {
      var target = event.target;
      var className = target.classList.item(0);
      if (className) {
        var objMethod = className.split('_');
        var obj = objMethod[0];
        var method = objMethod[1];
        if (obj && method) {
          this[obj][method].call(this, event);  
        }  
      }
    },

    initialize: function(panel) {
      this.panel = panel;          // TODO: should be this._panel
      var onPanelOpen = document.querySelector('div.onPanelOpen');
      onPanelOpen.addEventListener('click', this.onClick.bind(this));
    },
    
    close: function() {
      var logView = document.querySelector('div.logView');
      logView.classList.remove('initialView');
    },

    open: function() {
      var logView = document.querySelector('div.logView');
      logView.classList.add('initialView');
    },

    // Functions wired to eg hint_overview
    hint: {
      overview: function() {
        this.panel.toggleHelp();
      },
      documentation: function() {
        window.open("http://google.github.com/qpp/documentation.html");
      },
      feedback: function() {
        window.open("https://github.com/google/qpp/issues/new");
      }
    },
    initialOptions: {
      justReload: function () {
        this.panel.project.reload();
        this.close();
      },
      noReload: function() {
        this.close();
      }
    }
  }

}());
{'fraction_non_alphanumeric': 0.13955901426718548, 'fraction_numerical': 0.0038910505836575876, 'mean_word_length': 2.2485256950294863, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '71999', 'n_tokens_mistral': 1115, 'n_tokens_neox': 1096, 'n_words': 207}