Changeset 6015eee in sasview


Ignore:
Timestamp:
Sep 10, 2018 7:24:17 AM (6 years ago)
Author:
GitHub <noreply@…>
Branches:
master, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, unittest-saveload
Children:
a4a1ac9
Parents:
b229a3b (diff), b4398819 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
git-author:
Steve K <smk78@…> (09/10/18 07:24:17)
git-committer:
GitHub <noreply@…> (09/10/18 07:24:17)
Message:

Merge pull request #177 from SasView?/ticket-529_PluginModelDocFix

Fix blank page when clicking help on a plugin model

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sasgui/perspectives/fitting/basepage.py

    r8a51dea0 rb4398819  
    28012801        Function called when 'Help' button is pressed next to model 
    28022802        of interest.  This calls DocumentationWindow from 
    2803         documentation_window.py. It will load the top level of the model 
    2804         help documenation sphinx generated html if no model is presented. 
    2805         If a model IS present then if documention for that model exists 
    2806         it will load to that  point otherwise again it will go to the top. 
    2807         For Wx2.8 and below is used (i.e. non-released through installer) 
    2808         a browser is loaded and the top of the model documentation only is 
    2809         accessible because webbrowser module does not pass anything after 
    2810         the # to the browser. 
     2803        documentation_window.py. It will load the top level of the html model 
     2804        help documenation sphinx generated if either a plugin model (which 
     2805        normally does not have an html help help file) is selected or if no 
     2806        model is selected. Otherwise, if a regula model is selected, the 
     2807        documention for that model will be sent to a browser window. 
     2808 
     2809        :todo the quick fix for no documentation in plugins is the if statment. 
     2810        However, the right way to do this would be to check whether the hmtl 
     2811        file exists and load the model docs if it does and the general docs if 
     2812        it doesn't - this will become important if we ever figure out how to 
     2813        build docs for plugins on the fly.  Sep 9, 2018 -PDB 
    28112814 
    28122815        :param event: on Help Button pressed event 
    28132816        """ 
    28142817 
    2815         if self.model is not None: 
     2818        if (self.model is not None) and (self.categorybox.GetValue() 
     2819                                         != "Plugin Models"): 
    28162820            name = self.formfactorbox.GetValue() 
    28172821            _TreeLocation = 'user/models/%s.html' % name 
Note: See TracChangeset for help on using the changeset viewer.