search for: new_

Displaying 16 results from an estimated 16 matches for "new_".

Did you mean: new
2009 Feb 09
4
forms that mix new and old records
I''m trying to create a form/view that displays a mix of records that exist in the database and records that the user is working on but that don''t yet exist in the database. I want to leverage all of rails'' nice form helpers, especially the params hash that it generates for the records when the form is submitted. So - I am creating ''dummy'' records with
2010 Jul 08
1
[LLVMdev] X86 gcc and clang have incompatible calling conventions for returning some small structs?
...llo, I think I have come across an inconsistency between gcc and clang/llvm with respect to returning small structs. Given the following code: > struct s { > int a; > int b; > }; > > struct s3 { > int a; > int b; > int c; > }; > > struct s new_s(int v){ > struct s res; > res.a = v; > res.b = -v; > return res; > } > > struct s3 new_s3(int v){ > struct s3 res; > res.a = v; > res.b = -v; > res.c = v<<2; > return res; > } For the function new_s() both the curren...
2009 Jun 29
0
Problem with 2.3 nested forms and new elements
...gment **************** def add_linea_link(name, form) link_to_function name do |page| nueva_linea = @factura.lineas.build linea = render(:partial => ''linea'', :locals => { :pf => form, :linea => nueva_linea}) page << %{ var new_linea_id = "new_" + new Date().getTime(); $(''lineas'').insert({ bottom: "#{ escape_javascript linea }".replace(/new_\\d+/g, new_linea_id) }); } end end ********** _form.erb.html from facturas fragment ********** <table id="...
2015 Nov 21
1
[PATCH -qemu] nvme: support Google vendor extension
...-ro > > Then it doesn't response input for almost 1 minute. > Without this patch, kernel loads quickly. Interesting. I guess there's time to debug it, since QEMU 2.6 is still a few months away. In the meanwhile we can apply your patch as is, apart from disabling the "if (new_head >= cq->size)" and the similar one for "if (new_ tail >= sq->size". But, I have a possible culprit. In your nvme_cq_notifier you are not doing the equivalent of: start_sqs = nvme_cq_full(cq) ? 1 : 0; cq->head = new_head; if (start_sqs) {...
2007 Apr 17
3
DomU Kernel Mapping
Where is the code that maps the kernel of a DomU into memory? i.e, when you do a xm create <config file> what code is called to actually map the kernel into memory? Is it a python script or is it re-directed to Dom0 to do? Thanks. -Brian --------------------------------- Ahhh...imagining that irresistible "new car" smell? Check outnew cars at Yahoo! Autos.
2007 Apr 17
3
DomU Kernel Mapping
Where is the code that maps the kernel of a DomU into memory? i.e, when you do a xm create <config file> what code is called to actually map the kernel into memory? Is it a python script or is it re-directed to Dom0 to do? Thanks. -Brian --------------------------------- Ahhh...imagining that irresistible "new car" smell? Check outnew cars at Yahoo! Autos.
2006 Jun 15
0
Best practice for params key names for mapping to models
...;'m processing new records in the create method and updating records in the update method. I''d like to have one method to handle both create and update (an attempt to dry up my code). I''m using my own naming convention in params for new records, the model name with "new_" appended. I''m thinking how I might be able to right this all-in-one method (both create and update method). My hunch is that a proper naming scheme for the params keys would make it easier. -- Posted via http://www.ruby-forum.com/.
2006 Jan 02
2
Dynamic form tags
...tp://wiki.rubyonrails.com/rails/pages/HowToReuseEditViewsForNewViews There''s this comment there saying you only need the tag "<%= auto_form %>" when using the code below. Can somebody tell me if that will work when extending it with model_name (some how)? I have several new_* methods (e.g. new_contact, new_company, new_project, etc), and I''m not going to bother with this challenge when you big guys out there tell me it''s a no go to develop this. def auto_form action = case controller.action_name when "new" then "create"...
2010 Nov 01
2
Creating RESTful helpers on the fly
If I have a resource called ''assets'' then I get for free a bunch of helpers, like assets_path new_asset_path and so forth, right? I would like to be able to create a call to one of these on the fly when I only find out the name of the resource at run time. For example I would like to do this: resource_name = "assets" resource_path(resource_name, method => :new) Anyone know the R...
2015 Nov 20
2
[PATCH -qemu] nvme: support Google vendor extension
...nzini wrote: >> >> On 18/11/2015 06:47, Ming Lin wrote: >>> @@ -726,7 +798,11 @@ static void nvme_process_db(NvmeCtrl *n, hwaddr addr, int val) >>> } >>> >>> start_sqs = nvme_cq_full(cq) ? 1 : 0; >>> - cq->head = new_head; >>> + /* When the mapped pointer memory area is setup, we don't rely on >>> + * the MMIO written values to update the head pointer. */ >>> + if (!cq->db_addr) { >>> + cq->head = new_head; >>> + } &gt...
2015 Nov 20
2
[PATCH -qemu] nvme: support Google vendor extension
...nzini wrote: >> >> On 18/11/2015 06:47, Ming Lin wrote: >>> @@ -726,7 +798,11 @@ static void nvme_process_db(NvmeCtrl *n, hwaddr addr, int val) >>> } >>> >>> start_sqs = nvme_cq_full(cq) ? 1 : 0; >>> - cq->head = new_head; >>> + /* When the mapped pointer memory area is setup, we don't rely on >>> + * the MMIO written values to update the head pointer. */ >>> + if (!cq->db_addr) { >>> + cq->head = new_head; >>> + } &gt...
2006 Jul 14
7
Form validation - keepin correct fields displayed on refresh
All, I''m finally doing my first real form in Rails - the model object that I''m entering information for has 8 validations so far. If I type in good values for all the fields but one, I get the pretty validation, and the nice field highlighting, but all of the fields are cleared, forcing me to retype all of that info. That is a big drag. Is there a standard way to get the
2007 Aug 23
1
[nut-commits] svn commit r1073 - in trunk: . drivers
...nores the "Bus" field, because > - it can change during a reconnect. */ > - return 1; > + > + return 2; > } > > -/* constructor: return a new matcher that matches the exact HIDDevice_t > - * d. Return NULL with errno set on error. */ > -HIDDeviceMatcher_t *new_exact_matcher(HIDDevice_t *d) > +/* constructor: create an exact matcher that matches the device. > + * On success, return 0 and store the matcher in *matcher. On > + * error, return -1 with errno set > + */ > +int HIDNewExactMatcher(HIDDeviceMatcher_t **matcher, HIDDevice_t *hd) >...
2012 Apr 20
1
[PATCH] multiqueue: a hodge podge of things
...return -EINVAL; else { rq->biotail->bi_next = bio; rq->biotail = bio; rq->__data_len += bio->bi_size; } return 0; } diff --git a/block/blk-merge.c b/block/blk-merge.c index 160035f..61538b3 100644 --- a/block/blk-merge.c +++ b/block/blk-merge.c @@ -64,19 +64,21 @@ new_segment: fbio->bi_seg_front_size = seg_size; if (seg_size > bbio->bi_seg_back_size) bbio->bi_seg_back_size = seg_size; return nr_phys_segs; } void blk_recalc_rq_segments(struct request *rq) { - rq->nr_phys_segments = __blk_recalc_rq_segments(rq->q, rq->bio); + s...
2012 Apr 20
1
[PATCH] multiqueue: a hodge podge of things
...return -EINVAL; else { rq->biotail->bi_next = bio; rq->biotail = bio; rq->__data_len += bio->bi_size; } return 0; } diff --git a/block/blk-merge.c b/block/blk-merge.c index 160035f..61538b3 100644 --- a/block/blk-merge.c +++ b/block/blk-merge.c @@ -64,19 +64,21 @@ new_segment: fbio->bi_seg_front_size = seg_size; if (seg_size > bbio->bi_seg_back_size) bbio->bi_seg_back_size = seg_size; return nr_phys_segs; } void blk_recalc_rq_segments(struct request *rq) { - rq->nr_phys_segments = __blk_recalc_rq_segments(rq->q, rq->bio); + s...
2013 Jul 25
19
[PATCH hivex 00/19] Fix read/write handling of li-records.
This is, hopefully, a full fix for handling of li-records. See: https://bugzilla.redhat.com/show_bug.cgi?id=717583 https://bugzilla.redhat.com/show_bug.cgi?id=987463 Rich.