def location(): loc = Location() with edit_readonly(loc): loc.href = "http://localhost:5006" loc.hostname = "localhost" loc.pathname = "" loc.protocol = 'http' loc.search = "" loc.hash = "" return loc
def _set_busy(self, busy): """ Sets panel.state to busy if available. """ if 'busy' not in state.param: return # Check if busy state is supported from panel.util import edit_readonly with edit_readonly(state): state.busy = busy
def callback_busy_state(event): with edit_readonly(state): state.busy = True cb = functools.partial(callback, event) self.chart.document.add_next_tick_callback(cb) self.chart.document.add_next_tick_callback(release_state)
def release_state(): with edit_readonly(state): state.busy = False