components

How can I specify the Owner of component read from a Delphi TStream?

偶尔善良 提交于 2019-12-11 00:23:58
问题 I'm reading a component from a stream, and want to be able to specify the Owner property. var TComponent : comp; stream.Seek(0, soFromBeginning); comp := stream.ReadComponent(nil); Who owns comp, and how can I change it? I'd hoped the parameter to readComponent would be the owner, but it seems to do something totally different! 回答1: @Roddy, you can use the InsertComponent procedure for set the owner of an component. check this sample procedure TForm1.Button1Click(Sender: TObject); var Stream

How can I include multiple models in one view for in a Joomla 3.x component built with Component Creator

我怕爱的太早我们不能终老 提交于 2019-12-11 00:02:02
问题 Joomla components use the MVC model. Component Creator is a widely used tool whose paid level supports creation of multi tabled views with SQL import. Also, developers build components from scratch according to Joomla documentation. I want to build an advanced component that functions as a "dashboard" displaying data from multiple database tables with all the administrator back-end and visitor front-end CRUD (CREATE, READ, UPDATE, DELETE) capabilities of Joomla. This means that I need

How-to: Mapping (NHibernate) multiple classes with different business logic from the same table?

♀尐吖头ヾ 提交于 2019-12-10 22:01:04
问题 I am currently working with a brownfield database which contains a table which holds data for 3 different sorts of business. It has to do with SalesOrders and orderlines. In the old application, we were able to add 3 types of orderlines to each salesorder: products, hourly rates and text lines. 15 years ago, this was a quick and dirty solution to get easy queries in Delphi to get all the lines in one datagrid. Every Now I am trying to build the object model in C# using NHibernate. I've made 3

ColdFusion Components Inheriting Functions Of Others

天大地大妈咪最大 提交于 2019-12-10 21:28:05
问题 I have two simple CFCs as shown below: Test1.cfc <cfcomponent> <cffunction name="initMethod1" access="private" returntype="boolean"> <cfreturn true /> </cfcomponent> Test2.cfc <cfcomponent> <cffunction name="initMethod2" access="private" returntype="boolean"> <cfreturn true /> </cfcomponent> During OnApplicationStart() of Application.cfc, I make the following calls: <cfset application["Test1"] = CreateObject("component","jbx.c.Test1") /> <cfset application["Test2"] = CreateObject("component",

How to implement a self contained component in react redux?

孤街浪徒 提交于 2019-12-10 20:13:29
问题 I am building a file manager webui base on react redux(My purpose is to master react and redux through this project) As you know, a file manager need a tree explorer.I want to build a component which can contain it self and each has self state. like below: TreeNode can contain children which are TreeNode too.Each TreeNode hold its state {path, children_nodes, right .....} , children_nodes is get from server, path is passed by parent. That's what I imagine. Struct like: App: TreeNode -

TS2741 Property '0' is missing in type '{ label: string; } Javascript

人走茶凉 提交于 2019-12-10 19:29:43
问题 Hi I'm writing a code using JS and TS. I've made this interface: > interface IPLTableProps { > Conf: [{ key: string, val: any }], > Values?: [string], > children?: ReactNode // TODO prendere children da React } I defined this interface for create a general component. When I try to use this component in another file, obliviously I have to call is as a general component. But here it comes the error. The general component it's called PLTable <PLTable Conf={CONF}/> CONF is an array, and when I

Java own components visually connecting per drag and drop

不羁的心 提交于 2019-12-10 18:14:23
问题 I'm working on a software solution for a small workflow editor. For this I created an own JPanel with some functionality like deleting itself or editing the main information. This is how it looks: The point is, that i need a dynamic connector like a arrow or something like that. I tried it with drawline but its not dynamic and looks not well. I mean if I move one of the boxes so the drawed line have to change its position too. The boxes in the big JPanel are movable and resizable. The

Custom Swing component: questions on approach

依然范特西╮ 提交于 2019-12-10 18:08:36
问题 I'm trying to build a new java swing component, I realise that I might be able to find one that does what I need on the web, but this is partly an exercise for me to learn ow to do this. I want to build a swing component that represents a Gantt chart. it would be good (though not essential for people to be able to interact with it (e.g slide the the tasks around to adjust timings) it feels like the best approach for this is to subclass JComponent , and override PaintComponent() to 'draw a

Java: define unit component for mouse events

南楼画角 提交于 2019-12-10 18:08:30
问题 I want to have a JPanel called mainPanel and add several components on it; Also I defined a mouseAdapter and added to my mainPanel that overrides mouseEntered and mouseExited to for example change background color of mainPanel when mouse entered it. But when mouse entered to mainPanel and entered to components I added on it (for example labels) mouseExited event is called; But I don't want this as mouse is in area of mainPanel ; I want it be called just when mouse exited mainPanel area; and

vue.js wrapping components which have v-models

霸气de小男生 提交于 2019-12-10 17:28:31
问题 I have a 3rd party input component (a vuetify v-text-field). For reasons of validation i prefer to wrap this component in my own. my TextField.vue <template> <v-text-field :label="label" v-model="text" @input="onInput" @blur="onBlur" :error-messages="this.getErrors(this.validation, this.errors)" ></v-text-field> </template> <script> import VTextField from "vuetify/es5/components/VTextField"; import {vuelidateErrorsMixin} from '~/plugins/common.js'; export default { name: "TextField", props: [