示例#1
0
        public ProductObject(IServices services, IViews views, Transform parent, Product product) : base(services, views, parent)
        {
            this.product = product;

            AddListeners();
            SetSprite();
        }
示例#2
0
        public Popups(IServices services, IViews views)
        {
            Views    = views;
            Services = services;

            CreatePopups();
        }
示例#3
0
 protected Element(IServices services, IViews views, Transform parent)
 {
     Services = services;
     Views    = views;
     go       = Services.PrefabsService.Get(parent, GetType());
     refs     = go.GetComponent <T>();
 }
示例#4
0
        public void Init(IReferences references, IViews views)
        {
            Views = views;

            PrefabFactory     = new PrefabFactory(this, references.PrefabReferences);
            JsonService       = new JsonService(references, this);
            HTTPService       = new HTTPService(references, this);
            FoodSpriteService = new FoodSpriteService(references, this);
        }
示例#5
0
        public View(IServices services, IViews views)
        {
            this.services = services;
            this.views    = views;

            go = services.PrefabsService.Get(null, GetType());
            //TODO TRANSFORM
            go.SetActive(false);
            refs = refs.GetComponent <T>();
        }
示例#6
0
        public ShelfCreator(IServices services, IViews views, Transform transform)
        {
            this.services = services;
            this.views    = views;

            this.shelvesTransform = transform;

            Shelves = new Dictionary <string, List <IShelf> >();
            factory = new ShelfFactory(services, views);
        }
示例#7
0
        public IDrawingTables GetTables(IKompasDocument2D doc2d, string NameView) // получить интерфейс коллекции таблиц (входной параметр: имя вида расположения таблицы)
        {
            IViewsAndLayersManager ViewsManadger = doc2d.ViewsAndLayersManager;   // менеджер видов и слоев

            if (ViewsManadger == null)
            {
                //MessageBox.Show("Не удалось получить интерфейс IViewsAndLayersManager.");
                return(null);
            }
            IViews views = ViewsManadger.Views; // коллекция видов

            if (views == null)
            {
                // MessageBox.Show("Не удалось получить интерфейс IViews.");
                return(null);
            }
            IView viewSpecif = views.get_View(NameView); // вид с ведомостями

            if (viewSpecif == null)
            {
                viewSpecif = views.Add(LtViewType.vt_Normal);
                if (viewSpecif == null)
                {
                    //MessageBox.Show("Не удалось получить интерфейс IView.");
                    return(null);
                }
                viewSpecif.Name = NameView;
                viewSpecif.X    = 0;
                viewSpecif.Y    = 0;
                if (!(viewSpecif.Update()))
                {
                    MessageBox.Show("Не удалось обновить вид.");
                    return(null);
                }
            }
            viewSpecif.Current = true;
            viewSpecif.Update();

            ISymbols2DContainer ContainerTables = (ISymbols2DContainer)viewSpecif; // контейнер таблиц

            if (ContainerTables == null)
            {
                //MessageBox.Show("Не удалось получить интерфейс ISymbols2DContainer.");
                return(null);
            }
            IDrawingTables Tables = ContainerTables.DrawingTables; // коллекция таблиц

            if (Tables == null)
            {
                //MessageBox.Show("Не удалось получить интерфейс IDrawingTables.");
                return(null);
            }
            return(Tables);
        }
示例#8
0
文件: View.cs 项目: Nuzumi/Freezer
        protected View(IServices services, IViews views)
        {
            Services = services;
            Views    = views;
            go       = Services.PrefabFactory.Get(Views.CanvasTransform, GetType());
            go.SetActive(false);
            component           = go.GetComponent <T>();
            component.OnHidden += OnHidden;

            OnHideEvent = new OptimizedEvent();
            OnShowEvent = new OptimizedEvent();
        }
 private void ExpandViews(IViews views, TreeNode node)
 {
     if (HasBlankNode(node))
     {
         foreach (IView view in views)
         {
             TreeNode n = new TreeNode(view.Name);
             n.Tag = new NodeData(NodeType.VIEW, view);
             n.SelectedImageIndex = n.ImageIndex = 6;
             node.Nodes.Add(n);
             n.Nodes.Add(this.BlankNode);
         }
     }
 }
示例#10
0
文件: Client.cs 项目: RhysC/mycouch
        public Client(IConnection connection, ClientBootsraper bootstraper = null)
        {
            Ensure.That(connection, "connection").IsNotNull();

            Connection = connection;

            bootstraper = bootstraper ?? new ClientBootsraper();

            Serializer = bootstraper.SerializerFn();
            Attachments = bootstraper.AttachmentsFn(Connection);
            Databases = bootstraper.DatabasesFn(Connection);
            Documents = bootstraper.DocumentsFn(Connection);
            Entities = bootstraper.EntitiesFn(Connection);
            Views = bootstraper.ViewsFn(Connection);
        }
示例#11
0
文件: Client.cs 项目: RhysC/mycouch
        public Client(IConnection connection, ClientBootsraper bootstraper = null)
        {
            Ensure.That(connection, "connection").IsNotNull();

            Connection = connection;

            bootstraper = bootstraper ?? new ClientBootsraper();

            Serializer  = bootstraper.SerializerFn();
            Attachments = bootstraper.AttachmentsFn(Connection);
            Databases   = bootstraper.DatabasesFn(Connection);
            Documents   = bootstraper.DocumentsFn(Connection);
            Entities    = bootstraper.EntitiesFn(Connection);
            Views       = bootstraper.ViewsFn(Connection);
        }
示例#12
0
        public MyCouchClient(DbConnectionInfo connectionInfo, MyCouchClientBootstrapper bootstrapper = null)
        {
            Ensure.That(connectionInfo, "connectionInfo").IsNotNull();

            IsDisposed = false;
            bootstrapper = bootstrapper ?? MyCouchClientBootstrappers.Default;

            Connection = bootstrapper.DbConnectionFn(connectionInfo);
            Serializer = bootstrapper.SerializerFn();
            DocumentSerializer = bootstrapper.DocumentSerializerFn();
            Changes = bootstrapper.ChangesFn(Connection);
            Attachments = bootstrapper.AttachmentsFn(Connection);
            Database = bootstrapper.DatabaseFn(Connection);
            Documents = bootstrapper.DocumentsFn(Connection);
            Entities = bootstrapper.EntitiesFn(Connection);
            Views = bootstrapper.ViewsFn(Connection);
        }
示例#13
0
        public MyCouchClient(DbConnectionInfo connectionInfo, MyCouchClientBootstrapper bootstrapper = null)
        {
            Ensure.That(connectionInfo, "connectionInfo").IsNotNull();

            IsDisposed   = false;
            bootstrapper = bootstrapper ?? MyCouchClientBootstrappers.Default;

            Connection         = bootstrapper.DbConnectionFn(connectionInfo);
            Serializer         = bootstrapper.SerializerFn();
            DocumentSerializer = bootstrapper.DocumentSerializerFn();
            Changes            = bootstrapper.ChangesFn(Connection);
            Attachments        = bootstrapper.AttachmentsFn(Connection);
            Database           = bootstrapper.DatabaseFn(Connection);
            Documents          = bootstrapper.DocumentsFn(Connection);
            Entities           = bootstrapper.EntitiesFn(Connection);
            Views = bootstrapper.ViewsFn(Connection);
        }
示例#14
0
        public MyCouchClient(IDbClientConnection connection, MyCouchClientBootstrapper bootstrapper = null)
        {
            Ensure.That(connection, "connection").IsNotNull();

            Connection = connection;

            bootstrapper = bootstrapper ?? new MyCouchClientBootstrapper();

            Serializer         = bootstrapper.SerializerFn();
            DocumentSerializer = bootstrapper.DocumentSerializerFn();
            Changes            = bootstrapper.ChangesFn(Connection);
            Attachments        = bootstrapper.AttachmentsFn(Connection);
            Database           = bootstrapper.DatabaseFn(Connection);
            Documents          = bootstrapper.DocumentsFn(Connection);
            Entities           = bootstrapper.EntitiesFn(Connection);
            Views      = bootstrapper.ViewsFn(Connection);
            IsDisposed = false;
        }
示例#15
0
        public MyCouchClient(IDbClientConnection connection, MyCouchClientBootstrapper bootstrapper = null)
        {
            Ensure.That(connection, "connection").IsNotNull();

            Connection = connection;

            bootstrapper = bootstrapper ?? new MyCouchClientBootstrapper();

            Serializer = bootstrapper.SerializerFn();
            DocumentSerializer = bootstrapper.DocumentSerializerFn();
            Changes = bootstrapper.ChangesFn(Connection);
            Attachments = bootstrapper.AttachmentsFn(Connection);
            Database = bootstrapper.DatabaseFn(Connection);
            Documents = bootstrapper.DocumentsFn(Connection);
            Entities = bootstrapper.EntitiesFn(Connection);
            Views = bootstrapper.ViewsFn(Connection);
            IsDisposed = false;
        }
示例#16
0
 public AbstractShelf(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
     Products = new List <ProductObject>();
 }
示例#17
0
 public MainShelf(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
 }
		private void ExpandViews(IViews views, TreeNode node)
		{
			if(HasBlankNode(node))
			{
				foreach(IView view in views)
				{
					TreeNode n = new TreeNode(view.Name);
					n.Tag = new NodeData(NodeType.VIEW, view);
					n.SelectedImageIndex = n.ImageIndex = 6;
					node.Nodes.Add(n);
					n.Nodes.Add(this.BlankNode);
				}
			}
		}
示例#19
0
 public TouchInterceptor(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
     component.Button.onClick.AddListener(OnClick);
     go.SetActive(false);
 }
示例#20
0
 public MenuView(IServices services, IViews views) : base(services, views)
 {
     refs.welcomeText.text = "Kekeke";
     Show();
 }
示例#21
0
 private void CreateViews()
 {
     views = new Views(services, references);
     views.Init();
 }
示例#22
0
 public ProductDetailsPopup(IServices services, IViews views) : base(services, views)
 {
 }
示例#23
0
 public FridgePage(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
     ShelfCreator = new ShelfCreator(services, views, component.Shelves);
 }
示例#24
0
文件: Blend.cs 项目: Nuzumi/Freezer
 public Blend(IServices services, IViews views) : base(services, views)
 {
 }
示例#25
0
 public AddPage(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
     AddListeners();
 }
示例#26
0
文件: Popup.cs 项目: Nuzumi/Freezer
 protected Popup(IServices services, IViews views) : base(services, views)
 {
 }
示例#27
0
 public ShelfFactory(IServices Services, IViews Views)
 {
     this.services = Services;
     this.views    = Views;
 }
示例#28
0
 protected HideableElement(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
 }
示例#29
0
 public MainView(IServices services, IViews views) : base(services, views)
 {
     Pages = new Dictionary <PageType, IPage>();
     CreatePages();
     AddListeners();
 }
示例#30
0
 public PublicFridgesPage(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
     component.MapButton.onClick.AddListener(() => Application.OpenURL("https://www.google.com/maps/d/u/0/viewer?mid=1e4QtlB9Rv4dSEOGGzz-Zgtb7KuPX75WI&hl=pl&ll=52.103701462363745%2C19.94394496315215&z=7"));
 }
示例#31
0
 public SlackMessageSender(IViews views, Uri webHookUri)
 {
     _views       = views;
     _slackClient = new SlackClient(webHookUri);
 }
示例#32
0
 protected PageElement(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
     go.SetActive(false);
 }
示例#33
0
 public TheRecipe(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
 }
示例#34
0
 public RecepiesPage(IServices services, IViews views, Transform parent) : base(services, views, parent)
 {
 }