aboutsummaryrefslogtreecommitdiff
blob: 5db14c9c1f97986a1aee6000781d02e20e07e83f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
using System;
using KukaPizza.Controllers;

namespace KukaPizza.Views
{
    public abstract class View
    {
        private Controller _controller;
        public void Init(Controller controller)
        {
            _controller = controller;
            Draw();
            Interact();
        }

        protected abstract void Draw();
        protected abstract void Interact();

        public void NavigateTo(Type view)
        {
            Activator.CreateInstance(view, _controller);
        }
    }
}