# -*- coding: utf-8 -*-

"""
This class is created by Tiina Ferm
"""

from abc import ABC, abstractmethod
from tkinter import ttk

class Block(ttk.Frame, ABC):

    def __init__(self, parent):
        '''
        call Fram'se init method
        '''
        ttk.Frame.__init__(self, parent) #parent element e.g. TK or Frame where this Frame is in

    @abstractmethod
    def disable(self, nro):
        pass

    def disableAll(self):
        '''
        disable all buttons (self.buttons is assumed)
        '''
        for i in range(len(self.buttons)):
            self.buttons[i].config(state="disabled")

    def enableAll(self):
        '''
        enable all buttons (self.buttons is assumed)
        '''
        for i in range(len(self.buttons)):
            self.buttons[i].config(state="normal")




ecc53b37e892ddb8993d652c720f9805a41be1b4
<mask token>


class Block(ttk.Frame, ABC):
    <mask token>

    @abstractmethod
    def disable(self, nro):
        pass
    <mask token>

    def enableAll(self):
        """
        enable all buttons (self.buttons is assumed)
        """
        for i in range(len(self.buttons)):
            self.buttons[i].config(state='normal')

<mask token>


class Block(ttk.Frame, ABC):
    <mask token>

    @abstractmethod
    def disable(self, nro):
        pass

    def disableAll(self):
        """
        disable all buttons (self.buttons is assumed)
        """
        for i in range(len(self.buttons)):
            self.buttons[i].config(state='disabled')

    def enableAll(self):
        """
        enable all buttons (self.buttons is assumed)
        """
        for i in range(len(self.buttons)):
            self.buttons[i].config(state='normal')

<mask token>


class Block(ttk.Frame, ABC):

    def __init__(self, parent):
        """
        call Fram'se init method
        """
        ttk.Frame.__init__(self, parent)

    @abstractmethod
    def disable(self, nro):
        pass

    def disableAll(self):
        """
        disable all buttons (self.buttons is assumed)
        """
        for i in range(len(self.buttons)):
            self.buttons[i].config(state='disabled')

    def enableAll(self):
        """
        enable all buttons (self.buttons is assumed)
        """
        for i in range(len(self.buttons)):
            self.buttons[i].config(state='normal')

<mask token>
from abc import ABC, abstractmethod
from tkinter import ttk


class Block(ttk.Frame, ABC):

    def __init__(self, parent):
        """
        call Fram'se init method
        """
        ttk.Frame.__init__(self, parent)

    @abstractmethod
    def disable(self, nro):
        pass

    def disableAll(self):
        """
        disable all buttons (self.buttons is assumed)
        """
        for i in range(len(self.buttons)):
            self.buttons[i].config(state='disabled')

    def enableAll(self):
        """
        enable all buttons (self.buttons is assumed)
        """
        for i in range(len(self.buttons)):
            self.buttons[i].config(state='normal')

# -*- coding: utf-8 -*-

"""
This class is created by Tiina Ferm
"""

from abc import ABC, abstractmethod
from tkinter import ttk

class Block(ttk.Frame, ABC):

    def __init__(self, parent):
        '''
        call Fram'se init method
        '''
        ttk.Frame.__init__(self, parent) #parent element e.g. TK or Frame where this Frame is in

    @abstractmethod
    def disable(self, nro):
        pass

    def disableAll(self):
        '''
        disable all buttons (self.buttons is assumed)
        '''
        for i in range(len(self.buttons)):
            self.buttons[i].config(state="disabled")

    def enableAll(self):
        '''
        enable all buttons (self.buttons is assumed)
        '''
        for i in range(len(self.buttons)):
            self.buttons[i].config(state="normal")



