Skip to content

Commit

Permalink
Merge pull request #4144 from ccordoba12/fix-findinfiles
Browse files Browse the repository at this point in the history
PR: Some fixes for Find in files
  • Loading branch information
ccordoba12 authored Feb 15, 2017
2 parents 22cbe2f + 62758bb commit a8e2699
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
1 change: 1 addition & 0 deletions spyder/plugins/findinfiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ def register_plugin(self):
self.main.search_menu_actions += [MENU_SEPARATOR, findinfiles_action]
self.main.search_toolbar_actions += [MENU_SEPARATOR,
findinfiles_action]
self.refreshdir()

def refresh_plugin(self):
"""Refresh widget"""
Expand Down
9 changes: 3 additions & 6 deletions spyder/widgets/findinfiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -397,12 +397,9 @@ def __init__(self, parent, search_text, search_text_regexp, search_path,
for widget in [self.python_path, self.hg_manifest, self.custom_dir,
self.dir_combo, browse]:
hlayout3.addWidget(widget)

self.search_text.valid.connect(lambda valid: self.find.emit())
self.include_pattern.valid.connect(lambda valid: self.find.emit())
self.exclude_pattern.valid.connect(lambda valid: self.find.emit())
self.dir_combo.valid.connect(lambda valid: self.find.emit())


vlayout = QVBoxLayout()
vlayout.setContentsMargins(0, 0, 0, 0)
vlayout.addLayout(hlayout1)
Expand All @@ -411,7 +408,7 @@ def __init__(self, parent, search_text, search_text_regexp, search_path,
self.more_widgets = (hlayout2, hlayout3)
self.toggle_more_options(more_options)
self.setLayout(vlayout)

self.setSizePolicy(QSizePolicy.Expanding, QSizePolicy.Minimum)

@Slot(bool)
Expand Down

0 comments on commit a8e2699

Please sign in to comment.