##// END OF EJS Templates
* ConsoleWidget no longer stores contiguous identical lines...
epatters -
Show More
@@ -1496,11 +1496,14 b' class HistoryConsoleWidget(ConsoleWidget):'
1496 source, hidden, interactive)
1496 source, hidden, interactive)
1497
1497
1498 if executed and not hidden:
1498 if executed and not hidden:
1499 # Save the command unless it was a blank line.
1499 # Save the command unless it was an empty string or was identical
1500 # to the previous command.
1500 history = history.rstrip()
1501 history = history.rstrip()
1501 if history:
1502 if history and (not self._history or self._history[-1] != history):
1502 self._history.append(history)
1503 self._history.append(history)
1503 self._history_index = len(self._history)
1504
1505 # Move the history index to the most recent item.
1506 self._history_index = len(self._history)
1504
1507
1505 return executed
1508 return executed
1506
1509
@@ -10,6 +10,7 b' from PyQt4 import QtCore, QtGui'
10 # Local imports
10 # Local imports
11 from IPython.core.inputsplitter import InputSplitter
11 from IPython.core.inputsplitter import InputSplitter
12 from IPython.frontend.qt.base_frontend_mixin import BaseFrontendMixin
12 from IPython.frontend.qt.base_frontend_mixin import BaseFrontendMixin
13 from IPython.utils.io import raw_print
13 from IPython.utils.traitlets import Bool
14 from IPython.utils.traitlets import Bool
14 from bracket_matcher import BracketMatcher
15 from bracket_matcher import BracketMatcher
15 from call_tip_widget import CallTipWidget
16 from call_tip_widget import CallTipWidget
@@ -432,8 +433,8 b' class FrontendWidget(HistoryConsoleWidget, BaseFrontendMixin):'
432 payload = msg['content']['payload']
433 payload = msg['content']['payload']
433 for item in payload:
434 for item in payload:
434 if not self._process_execute_payload(item):
435 if not self._process_execute_payload(item):
435 warning = 'Received unknown payload of type %s\n'
436 warning = 'Warning: received unknown payload of type %s'
436 self._append_plain_text(warning % repr(item['source']))
437 raw_print(warning % repr(item['source']))
437
438
438 def _process_execute_payload(self, item):
439 def _process_execute_payload(self, item):
439 """ Process a single payload item from the list of payload items in an
440 """ Process a single payload item from the list of payload items in an
General Comments 0
You need to be logged in to leave comments. Login now