Set do not disturb.
504553
def do_not_disturb(self, enabled):
        """"""
        self._set_setting(
            {
                CONST.SETTINGS_DO_NOT_DISTURB: str(enabled).lower()
            })
37639
def donotify(nick, rest):
	""
	opts = rest.split(' ')
	to = opts[0]
	Notify.store.notify(nick, to, ' '.join(opts[1:]))
	return "Will do!"
1227070
def enable_disable(self):
        
        if self.enabled:
            self.update(enabled=False)
        else:
            self.update(enabled=True)
214121
def notify_all(self):
        """"""
        self.condition.acquire()
        # python 3.x
        try:
            self.condition.notify_all()
        except:
            self.condition.notifyAll()
        self.condition.release()
429140
def set_off_mask(self, mask):
        """"""
        set_cmd = self._create_set_property_msg('_off_mask', 0x03, mask)
        self._send_method(set_cmd, self._property_set)
335882
def setBusy(self, busy):
        '''
        
        '''
        self._busy = busy
        if not self._busy:
            self._pump()
293600
def setIfMissing(self, key, value):
        """"""
        if self.get(key) is None:
            self.set(key, value)
        return self
98035
def set_off(self):
        """"""
        try:
            request = requests.post(
                '{}/{}/{}/'.format(self.resource, URI, self._mac),
                data={'action': 'off'}, timeout=self.timeout)
            if request.status_code == 200:
                pass
        except requests.exceptions.ConnectionError:
            raise exceptions.MyStromConnectionError()
480333
function(opts, fm) {
				if (fm.UA.Mobile || fm.UA.ltIE8) {
					this.disabled = true;
				}
			}
442912
def stop_listening(cls, event, func):
        """"""
        signal(event).disconnect(func, sender=cls)
181549
def disable(self, threads=True):
        
        if self.enabled_start:
            sys.settrace(None)
            self._disable()
        else:
            warn('Duplicate "disable" call')
1247425
def _hide(self):
        """"""
        self._icon.set_visible(False)
        self._icon.disconnect(self._conn_left)
        self._icon.disconnect(self._conn_right)
        self._conn_left = None
        self._conn_right = None
620039
def _disable_encryption(self):
        # () -> None
        """"""
        self.encrypt = self._disabled_encrypt
        self.decrypt = self._disabled_decrypt
476565
def mute(self, mute):
        """"""
        try:
            if mute:
                if self.send_get_command(self._urls.command_mute_on):
                    self._mute = STATE_ON
                    return True
                else:
                    return False
            else:
                if self.send_get_command(self._urls.command_mute_off):
                    self._mute = STATE_OFF
                    return True
                else:
                    return False
        except requests.exceptions.RequestException:
            _LOGGER.error("Connection error: mute command not sent.")
            return False
563214
def p_disable(self, p):
        ''
        p[0] = Disable(p[2], lineno=p.lineno(1))
        p.set_lineno(0, p.lineno(1))
1291645
def mute(ip):
        """"""
        tv_url = 'http://{}:6095/controller?action=keyevent&keycode='.format(ip)

        count = 0
        while count > 30:
            count = count + 1
            request = requests.get(tv_url + 'volumedown')

            if request.status_code != 200:
                return False

        return True
773835
def stop_listening(self):
        """"""
        self._halt_threads = True
        # wake them up so that they can die
        for name, queue_waker in self.recieved_signals.items():
            q, wake_event = queue_waker
            wake_event.set()