Search Results

Search found 9594 results on 384 pages for 'adf adf faces and ui'.

Page 11/384 | < Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >

  • Oracle ADF and Simplified UI Apps: I18n Feng Shui on Display

    - by ultan o'broin
    I demoed the Hebrew language version of Oracle Sales Cloud Release 8 live in Israel recently. The crowd was yet again wowed by the simplified UI (SUI). I’ve now spent some time playing around with most of the 23 language versions, or the NLS (Natural Language Support) versions as we’d call them, available in Release 8. Hebrew Oracle Sales Cloud Release 8 The simplified UI is built using 100% Oracle ADF. This framework is a great solution for developers to productively build tablet-first, mobility-driven apps for users who work and live using natural languages other than English. Oracle ADF’s internationalization (i18n) relies on built-in Java and Unicode,  packing in i18n goodness such as Bi-Di (or bi-directional) flipping of pages, locale-enabled resource bundles, date and time support, and so on. Comparing German (left) and Hebrew Bi-Di (right) page components in the simplified UI. Note the change in the direction of the arrows and positions of the text. So, developers who need to build global apps don’t have to do anything special when using Oracle ADF components, all thanks to the baked-in UX Feng Shui, as Grant Ronald of the ADF team would say to the UK Oracle User Group. Find out more  about  ADF i18n from Frédéric Desbiens (@blueberrycoder)  on the ADF Architecture TV channel.

    Read the article

  • Tip: Keeping the ADF Mobile PDF Guide up to date

    - by Chris Muir
    This is a little tip for customers using Oracle's ADF Mobile. If you're like me, it's possible you don't rely on the online HTML version of the Mobile Developer's Guide for ADF, but rather download a PDF version of the file to use locally (look to the "PDF" link to the top right of the guide).  For me the convenience of the PDF is it's faster, I can search the whole document easily, I can split read the document across two pages on my home monitor, if I lose my internet connection the document is still available, and it's easy to read on my iPad (especially on long haul flights to the US across the Pacific where there is no internet connection!). The trigger point for me to download the Oracle PDF documentation has always been on a new point release of JDeveloper.  However in the case of ADF Mobile, as an extension to JDeveloper it is releasing at a much faster and independent schedule to JDeveloper and this includes updates to the documentation. As such the 11.1.2.4.0 ADF Mobile PDF guide you have locally might be out of date and you should take the opportunity to download the latest version.  This is also particularly important for ADF Mobile as not only are many new features being added for each release and included in the new documentation, but the guide is under rapid improvement to clarify much of what has been written to date.  Our documentation teams are super responsive to suggestions on how to improve the guides and this often shows per point release. How do you tell you've the latest guide? Look to the document part number which right now is "E24475-03".  This is a unique ID per release for the document, the first part being the document number, and the part after the dash the revision number.  If the website document number has a higher revision number, time to download a new up to date PDF. One last thing to share, you can follow the ADF Mobile guide document manager Brian Duffield on Twitter to keep abreast of updates. Image courtesy of Stuart Miles / FreeDigitalPhotos.net

    Read the article

  • Accessing ADF Faces components that are read-only from JavaScript

    - by Frank Nimphius
    Almost as a note to myself and to justify the time I spent on analyzing aproblem, a quick note on what to watch out for when working trying to access read-only ADF Faces components from JavaScript.  Those who tried JavaScript in ADF Faces probably know that you need to ensure the ADF Faces component  is represented by a JavaScript object on the client. You do this either implicitly by adding an af:clientListener component (in case you want to listen for a component event) or explicitly by setting the ADF Faces component clientComponent property to true. For the use case I looked at in JDeveloper 11g R1 (11.1.1.7) I needed to make an output text component clickable to call a JavaScript function in response. Though I added the af:clientComponent tag to the component I recognized that it also needed the clientComponent property set to true. Though I remember this as not being required in 11.1.1.6, I like the new behavior as it helps preventing read-only components from firing client side events unless you tell it to do so by setting the clientComponent property to true. Note: As the time of writing, JDeveloper 11.1.1.7 is not publicly available and I put the note in this blog as a reminder in case you ever hit a similar challenge so you know what to do.

    Read the article

  • how to apply jquery ui draggable more than one time to same element

    - by Nuwan Chathuranga
    How can I apply jquery ui draggable or resizable more than one time to same element? For example: <div style="height: 50px; left: 216px; position: absolute; top: 64px; width: 444px; z-index: 1; class="test-12 ui-resizable ui-draggable" id="div-77"> <div class="ui-resizable-handle ui-resizable-e" style="z-index: 1000;"></div> <div class="ui-resizable-handle ui-resizable-s" style="z-index: 1000;"></div> <div class="ui-resizable-handle ui-resizable-se ui-icon ui-icon-gripsmall-diagonal-se" style="z-index: 1000;"></div> <div class="ui-rotatable-handle ui-draggable show"></div> </div> I want to apply jquery draggable and resizable to this div (id=div-77) with these other divs thank you

    Read the article

  • PanelGridLayout - A Layout Revolution

    - by Duncan Mills
    With the most recent 11.1.2 patchset (11.1.2.3) there has been a lot of excitement around ADF Essentials (and rightly so), however, in all the fuss I didn't want an even more significant change to get missed - yes you read that correctly, a more significant change! I'm talking about the new panelGridLayout component, I can confidently say that this one of the most revolutionary components that we've introduced in 11g, even though it sounds rather boring. To be totally accurate, panelGrid was introduced in 11.1.2.2 but without any presence in the component palette or other design time support, so it was largely missed unless you read the release notes. However in this latest patchset it's finally front and center. Its time to explore - we (really) need to talk about layout.  Let's face it,with ADF Faces rich client, layout is a rather arcane pursuit, once you are a layout master, all bow before you, but it's more of an art than a science, and it is often, in fact, way too difficult to achieve what should (apparently) be a pretty simple. Here's a great example, it's a homework assignment I set for folks I'm teaching this stuff to:  The requirements for this layout are: The header is 80px high, the footer is 30px. These are both fixed.  The first section of the header containing the logo is 180px wide The logo is centered within the top left hand corner of the header  The title text is start aligned in the center zone of the header and will wrap if the browser window is narrowed. It should be aligned in the center of the vertical space  The about link is anchored to the right hand side of the browser with a 20px gap and again is center aligned vertically. It will move as the browser window is reduced in width. The footer has a right aligned copyright statement, again middle aligned within a 30px high footer region and with a 20px buffer to the right hand edge. It will move as the browser window is reduced in width. All remaining space is given to a central zone, which, in this case contains a panelSplitter. Expect that at some point in time you'll need a separate messages line in the center of the footer.  In the homework assigment I set I also stipulate that no inlineStyles can be used to control alignment or margins and no use of other taglibs (e.g. JSF HTML or Trinidad HTML). So, if we take this purist approach, that basic page layout (in my stock solution) requires 3 panelStretchLayouts, 5 panelGroupLayouts and 4 spacers - not including the spacer I use for the logo and the contents of the central zone splitter - phew! The point is that even a seemingly simple layout needs a bit of thinking about, particulatly when you consider strechting and browser re-size behavior. In fact, this little sample actually teaches you much of what you need to know to become vaguely competant at layouts in the framework. The underlying result of "the way things are" is that most of us reach for panelStretchLayout before even finishing the first sip of coffee as we embark on a new page design. In fact most pages you will see in any moderately complex ADF page will basically be nested panelStretchLayouts and panelGroupLayouts, sometimes many, many levels deep. So this is a problem, we've known this for some time and now we have a good solution. (I should point out that the oft-used Trinidad trh tags are not a particularly good solution as you're tie-ing yourself to an HTML table based layout in that case with a host of attendent issues in resize and bi-di behavior, but I digress.) So, tadaaa, I give to you panelGridLayout. PanelGrid, as the name suggests takes a grid like (dare I say slightly gridbag-like) approach to layout, dividing your layout into rows and colums with margins, sizing, stretch behaviour, colspans and rowspans all rolled in, all without the use of inlineStyle. As such, it provides for a much more powerful and consise way of defining a layout such as the one above that is actually simpler and much more logical to design. The basic building blocks are the panelGridLayout itself, gridRow and gridCell. Your content sits inside the cells inside the rows, all helpfully allowing both streching, valign and halign definitions without the need to nest further panelGroupLayouts. So much simpler!  If I break down the homework example above my nested comglomorate of 12 containers and spacers can be condensed down into a single panelGrid with 3 rows and 5 cell definitions (39 lines of source reduced to 24 in the case of the sample). What's more, the actual runtime representation in the browser DOM is much, much simpler, and clean, with basically one DIV per cell (Note that just because the panelGridLayout semantics looks like an HTML table does not mean that it's rendered that way!) . Another hidden benefit is the runtime cost. Because we can use a single layout to achieve much more complex geometries the client side layout code inside the browser is having to work a lot less. This will be a real benefit if your application needs to run on lower powered clients such as netbooks or tablets. So, it's time, if you're on 11.1.2.2 or above, to smile warmly at your panelStretchLayouts, wrap the blanket around it's knees and wheel it off to the Sunset Retirement Home for a well deserved rest. There's a new kid on the block and it wants to be your friend. 

    Read the article

  • Build Mobile App for E-Business Suite Using SOA Suite and ADF Mobile

    - by Michelle Kimihira
    With the upcoming release of Oracle ADF Mobile, I caught up with Srikant Subramaniam, Senior Principal Product Manager, Oracle Fusion Middleware post OpenWorld to learn about the cool hands-on lab at OpenWorld.  For those of you who missed it, you will want to keep reading... Author: Srikant Subramaniam, Senior Principal Product Manager,Oracle Fusion Middleware Oracle ADF Mobile enables rapid and declarative development of native on-device mobile applications. These native applications provide a richer experience for smart devices users running Apple iOS or other mobile platforms. Oracle ADF Mobile protects Oracle customers from technology shifts by adopting a metadata-based development framework that enables developer to develop one app (using Oracle JDeveloper), and deploy to multiple device platforms (starting with iOS and Android).  Oracle ADF Mobile also enables IT organizations to leverage existing expertise in web-based and Java development by adopting a hybrid application architecture that brings together HTML5, Java, and device native container: HTML5 allows developer to deliver device-native user experiences while maintaining portability across different platforms Java allows developers to create modules to support business logic and data services Native container provides integration into device services such as camera, contacts, etc All these technologies are packaged into a development framework that supports declarative application development through Oracle JDeveloper. ADF Mobile also provides out of box integratoin with key Fusion Middleware components, such as SOA Suite and Business Process Management (BPM). Oracle Fusion Middleware provides the necessary infrastructure to extend business processes and services to the mobile device -- enabling the mobile user to participate in human tasks – without the additional “mobile middleware” layer. When coupled with Oracle SOA Suite, this combination can execute business transactions on Oracle E-Business Suite (or any Oracle Application). Demo Use Case: Mobile E-Business Suite (iExpense) Approvals Using an employee expense approval scenario, we illustrate how to use Oracle Fusion Middleware and Oracle ADF Mobile to build application extensions that integrate intelligently with Oracle Applications (For example, E-Business Suite). Building these extensions using Oracle Fusion middleware and ADF makes modifications simple, quick to implement, and easy to maintain/upgrade. As described earlier, this approach also extends Fusion Middleware to mobile users without the additional "Mobile Middleware" layer. The approver is presented with a list of expense reports that have been submitted for approval. These expense reports are retrieved from the backend E-Business Suite and displayed on the mobile device. Approval (or rejection) of the expense report kicks off the workflow in E-Business Suite and takes it to completion. The demo also shows how to integrate with native device services such as email, contacts, BI dashboards as well as a prebuilt PDF viewer (this is especially useful in the expense approval scenario, as there is often a need for the approver to access the submitted receipts). Summary Oracle recommends Fusion Middleware as the application integration platform to deliver critical enterprise data and processes to mobile applications.  Pre-built connectors between Fusion Middleware and Applications greatly accelerates the integration process.  Instead of building individual integration points between mobile applications and individual enterprise applications, Oracle Fusion Middleware enables IT organizations to leverage a common platform to support both desktop and mobile application.  Additional Information Product Information on Oracle.com: Oracle Fusion Middleware Follow us on Twitter and Facebook Subscribe to our regular Fusion Middleware Newsletter

    Read the article

  • kendo ui filtering the grid table, need some idea

    - by cool_spirit
    I want to filter the table by last name, but cant work, here is my code in controller public JsonResult Filtering() { HealthContext rc = new HealthContext(); var last = rc.Profiles.Select(lastt => new SelectListItem { Text = lastt.LastName, Value = lastt.Id.ToString() }).ToList(); return Json(last.ToList(), JsonRequestBehavior.AllowGet); } in view <script type="text/x-kendo-template" id="template"> <div class="toolbar"> <label class="category-label" for="Last name"> by last name:</label> <input type="search" id="LastName" style="width: 230px"></input> </div> </script> and also <script> $(document).ready(function() { $("#grid").kendoGrid({ dataSource: { transport: { read: { url: "/Profiles/GetJsonData", dataType: "json" } }, pageSize: 10, }, toolbar: kendo.template($("#template").html()), height: 250, filterable: true, sortable: true, pageable: true, defaultSorting: 'LastName ASC', columns: [{ field: "Id", filterable: false }, { field: "FirstName", title: "First Name", width: 100, }, { field: "LastName", title: "Last Name", width: 200 }, { field: "Gender", title: "Gender" } ] }); var dropDown = grid.find("#LastName").kendoDropDownList({ dataTextField: "LastName", dataValueField: "Id", autoBind: false, optionLabel: "All", dataSource: { severFiltering: true, transport: { read: { url: "/Profiles/Filtering", dataType: "json" } }, }, change: function() { var value = this.value(); if (value) { grid.data("kendoGrid").dataSource.filter({ field: "Id", operator: "eq", value: parseInt(value) }); } else { grid.data("kendoGrid").dataSource.filter({}); } } }); }); </script> so the problem is the drop down list is not show up as well as the value/ data, any idea guys?

    Read the article

  • jquery ui autocomplete problem

    - by Roger
    Hi, i've got a select box containing countries, and when one is selected, i want my autocomplete data for the city field to load via ajax. here's my code: // Sets up the autocompleter depending on the currently // selected country $(document).ready(function() { var cache = getCities(); $('#registration_city_id').autocomplete( { source: cache } ); cache = getCities(); // update the cache array when a different country is selected $("#registration_country_id").change(function() { cache = getCities(); }); }); /** * Gets the cities associated with the currently selected country */ function getCities() { var cityId = $("#registration_country_id :selected").attr('value'); return $.getJSON("/ajax/cities/" + cityId + ".html"); } This returns the following json: ["Aberdare","Aberdeen","Aberystwyth","Abingdon","Accrington","Airdrie","Aldershot","Alfreton","Alloa","Altrincham","Amersham","Andover","Antrim","Arbroath","Ardrossan","Arnold","Ashford","Ashington","Ashton-under-Lyne","Atherton","Aylesbury","Ayr",... ] But, it doesn't work. When i start typing in the city box, the style changes so the autocompleter is doing something, but it won't display this data. If i hard-code the above it works. Can anyone see what's wrong? Thanks

    Read the article

  • JQuery UI sortable: restore position based on some condition

    - by dafi
    I call sortable.stop() to make an ajax call to store some data after drag&drop operation. When the ajax call returns an error (application logic error or net problem) I want to move the dragged element to its original/start position, how can I achieve it? The scenario should be user drags A to B the sortable.stop() event is called, it triggers an ajax call the ajax call returns an error inside the stop() event we get the ajax error move A to its original position user again move A to B everything is ok A remains in its new position in B Steps 6-8 are shown to clarify a successive drag can be done and previous error must be forgotten

    Read the article

  • jQuery UI tabs link for _blank webpage

    - by Megawolt
    Hi fellas, In our format some pages must be in Tabs that's ok. But some of them must be open in a blank page... So How can i do that. I have try ; $('#tablar #tabs ul li a').filter(function() { return $(this).attr('rel') == 'ex'; }) .unbind() .click(function(e) { location.href = this.href; e.preventDefault(); }); But not working...

    Read the article

  • background image for jquery ui dialog buttons

    - by mcgrailm
    is it possible to give a button a background image really i have an image that I want to use for a button and would be nice if they stayed in place like the default buttons. right now I just have them inside the dialog but the rest of the content is dynamic and I don't want them to disappear when the scroll bar appears

    Read the article

  • jQuery Resizable() UI Problem

    - by OneNerd
    In general, resizable() works fine. Here is where I am getting into an issue. I have a div that contains some resizable items that work fine (resizable() applied to them at some point). user can save items for later view (the innerHTML of the div gets saved into a JavaScript array, then div gets cleared so they can do something else) When items get placed back onto div (from array) -- I do a $('#divname').append(arrayname[i]); -- items are no longer resizable (although visually they have the resizable classes/handle on them) Here is what I have tried so far (none of which have worked): After append() line, I re-initialize the resizable -- $('#items').resizable(); After append() line, remove then re-add resizable -- $('#items').resizable('destroy').resizable(); Any help is appreciated - thanks.

    Read the article

  • jQuery UI AutoComplete remote json response question

    - by Greg-J
    I was using geonames.org to autocomplete city and state but found it to be far too slow to be reliable. My code is as follows, and does work (wait about 10 seconds to see the autocomplete results) Old (working) code here: http://jsbin.com/umewo3/2/edit Now I am using YQL as they provide a much quicker response. The issue is that I don't seem to understand how to properly map the response. You can see I am sending a well formed request, and getting the response back - but I am somehow not dealing with the response properly. New (broken) code here: http://jsbin.com/aqoke3/2/edit Any and all help appreciated.

    Read the article

  • JSF 2.0 Problem (faces-config)

    - by Sarang
    Hello everybody, We have faces-config.xml in JSF 1.0 where we entry about managed-beans, dependencies & navigations etc. I was developing a sample project using JSF 2.0. But, as I don't know annotation, I need to include face-config.xml externally. Please, provide the solution for it, as in JSF 2.0 we don't need to include it. What is reason behind it ? How do we set a bean as managed-bean. What is annotation ? How is it used ? Thanking you.

    Read the article

  • JQuery UI question, how do you add variables into the dialog box

    $('.openDialog').click(function(event){ var width=$(this).attr('width'); var height=$(this).attr('height'); alert(width + ' ' + height); event.preventDefault(); $("#dialog").dialog({autoOpen: false, modal: true}); $('#dialog').dialog('option', 'width', width); $('#dialog').dialog('open'); $('#dialog p').load('http://pagetoload.com/page.html .content'); }); As you can see above i'm trying to open a dialog box with a passed in parameter of width and height, however when I try and pass in the value of width on this line: $('#dialog').dialog('option', 'width', width); it doesn't work, any ideas why or how to get around that? Thanks

    Read the article

  • Toggle jQuery-UI widgets

    - by cf_PhillipSenn
    I have: <div class="ui-widget"> <div class="ui-widget-header"> <span class="ui-icon ui-icon-circle-triangle-n">My Menu</span> </div> <ul class="ui-widget-content"> <li>Menu Item 1</li> <li>Menu Item 2</li> <li>Menu Item 3</li> </ul> </div> My jQuery is: $('.ui-widget-header').click(function() { $('.ui-widget-header+ul').toggle('slow'); }); Q: How do I toggle classes between ui-icon-circle-triangle-n and ui-icon-circle-triangle-s as the user clicks on .ui-widget-header?

    Read the article

  • sortable list using jquery ui not passing updated list order

    - by Matthew Berman
    I am following the sortable lists railscast and got everything working except when I sort, the same (original) order gets passed to the update method each time, so it doesn't update the true order. Here's the code: In the view: %tbody#lineup{"data-update-url" => sort_lineups_url} - @lineup.pieces.each_with_index do |piece, index| = content_tag_for :tr, piece do = render 'piece', :piece => piece, :index => index and pieces.js.coffee: jQuery -> $('#lineup').sortable( axis: 'y' update: -> $.post($(this).data('update-url'), $(this).sortable('serialize')) ); sort and show methods of lineupscontroller: def show @lineup = Lineup.find_by_user_id(current_user.id) @pieces = @lineup.pieces.order("position") end def sort params[:piece].each_with_index do |id, index| current_user.lineup.pieces.update_all({position: index+1}, {id: id}) end render nothing: true end and the update request: Started POST "/lineups/sort" for 127.0.0.1 at 2012-06-24 20:06:14 -0700 Processing by LineupsController#sort as */* Parameters: {"piece"=>["8", "2", "1", "4", "3", "7"]} User Load (0.4ms) SELECT `users`.* FROM `users` WHERE `users`.`id` = 2 LIMIT 1 Lineup Load (0.6ms) SELECT `lineups`.* FROM `lineups` WHERE `lineups`.`user_id` = 2 LIMIT 1 SQL (2.9ms) UPDATE `pieces` INNER JOIN `piece_lineups` ON `pieces`.`id` = `piece_lineups`.`piece_id` SET `position` = 1 WHERE `piece_lineups`.`lineup_id` = 3 AND `pieces`.`id` = 8 SQL (0.6ms) UPDATE `pieces` INNER JOIN `piece_lineups` ON `pieces`.`id` = `piece_lineups`.`piece_id` SET `position` = 2 WHERE `piece_lineups`.`lineup_id` = 3 AND `pieces`.`id` = 2 SQL (0.6ms) UPDATE `pieces` INNER JOIN `piece_lineups` ON `pieces`.`id` = `piece_lineups`.`piece_id` SET `position` = 3 WHERE `piece_lineups`.`lineup_id` = 3 AND `pieces`.`id` = 1 SQL (0.5ms) UPDATE `pieces` INNER JOIN `piece_lineups` ON `pieces`.`id` = `piece_lineups`.`piece_id` SET `position` = 4 WHERE `piece_lineups`.`lineup_id` = 3 AND `pieces`.`id` = 4 SQL (0.6ms) UPDATE `pieces` INNER JOIN `piece_lineups` ON `pieces`.`id` = `piece_lineups`.`piece_id` SET `position` = 5 WHERE `piece_lineups`.`lineup_id` = 3 AND `pieces`.`id` = 3 SQL (0.5ms) UPDATE `pieces` INNER JOIN `piece_lineups` ON `pieces`.`id` = `piece_lineups`.`piece_id` SET `position` = 6 WHERE `piece_lineups`.`lineup_id` = 3 AND `pieces`.`id` = 7 Rendered text template (0.0ms) so each time i drag+drop the list, it sends the same order again. what am I doing wrong that the params isn't passing the right, updated order? Completed 200 OK in 2757ms (Views: 1.0ms | ActiveRecord: 6.7ms)

    Read the article

  • Controlling the Sizing of the af:messages Dialog

    - by Duncan Mills
    Over the last day or so a small change in behaviour between 11.1.2.n releases of ADF and earlier versions has come to my attention. This has concerned the default sizing of the dialog that the framework automatically generates to handle the display of JSF messages being handled by the <af:messages> component. Unlike a normal popup, you don't have a physical <af:dialog> or <af:window> to set the sizing on in your page definition, so you're at the mercy of what the framework provides. In this case the framework now defines a fixed 250x250 pixel content area dialog for these messages, which can look a bit weird if the message is either very short, or very long. Unfortunately this is not something that you can control through the skin, instead you have to be a little more creative. Here's the solution I've come up with.  Unfortunately, I've not found a supportable way to reset the dialog so as to say  just size yourself based on your contents, it is actually possible to do this by tweaking the correct DOM objects, but I wanted to start with a mostly supportable solution that only uses the best practice of working through the ADF client side APIs. The Technique The basic approach I've taken is really very simple.  The af:messages dialog is just a normal richDialog object, it just happens to be one that is pre-defined for you with a particular known name "msgDlg" (which hopefully won't change). Knowing this, you can call the accepted APIs to control the content width and height of that dialog, as our meerkat friends would say, "simples" 1 The JavaScript For this example I've defined three JavaScript functions.   The first does all the hard work and is designed to be called from server side Java or from a page load event to set the default. The second is a utility function used by the first to validate the values you're about to use for height and width. The final function is one that can be called from the page load event to set an initial default sizing if that's all you need to do. Function resizeDefaultMessageDialog() /**  * Function that actually resets the default message dialog sizing.  * Note that the width and height supplied define the content area  * So the actual physical dialog size will be larger to account for  * the chrome containing the header / footer etc.  * @param docId Faces component id of the document  * @param contentWidth - new content width you need  * @param contentHeight - new content height  */ function resizeDefaultMessageDialog(docId, contentWidth, contentHeight) {   // Warning this value may change from release to release   var defMDName = "::msgDlg";   //Find the default messages dialog   msgDialogComponent = AdfPage.PAGE.findComponentByAbsoluteId(docId + defMDName); // In your version add a check here to ensure we've found the right object!   // Check the new width is supplied and is a positive number, if so apply it.   if (dimensionIsValid(contentWidth)){       msgDialogComponent.setContentWidth(contentWidth);   }   // Check the new height is supplied and is a positive number, if so apply it.   if (dimensionIsValid(contentHeight)){       msgDialogComponent.setContentHeight(contentHeight);   } }  Function dimensionIsValid()  /**  * Simple function to check that sensible numeric values are   * being proposed for a dimension  * @param sampleDimension   * @return booolean  */ function dimensionIsValid(sampleDimension){     return (!isNaN(sampleDimension) && sampleDimension > 0); } Function  initializeDefaultMessageDialogSize() /**  * This function will re-define the default sizing applied by the framework   * in 11.1.2.n versions  * It is designed to be called with the document onLoad event  */ function initializeDefaultMessageDialogSize(loadEvent){   //get the configuration information   var documentId = loadEvent.getSource().getProperty('documentId');   var newWidth = loadEvent.getSource().getProperty('defaultMessageDialogContentWidth');   var newHeight = loadEvent.getSource().getProperty('defaultMessageDialogContentHeight');   resizeDefaultMessageDialog(documentId, newWidth, newHeight); } Wiring in the Functions As usual, the first thing we need to do when using JavaScript with ADF is to define an af:resource  in the document metaContainer facet <af:document>   ....     <f:facet name="metaContainer">     <af:resource type="javascript" source="/resources/js/hackMessagedDialog.js"/>    </f:facet> </af:document> This makes the script functions available to call.  Next if you want to use the option of defining an initial default size for the dialog you use a combination of <af:clientListener> and <af:clientAttribute> tags like this. <af:document title="MyApp" id="doc1">   <af:clientListener method="initializeDefaultMessageDialogSize" type="load"/>   <af:clientAttribute name="documentId" value="doc1"/>   <af:clientAttribute name="defaultMessageDialogContentWidth" value="400"/>   <af:clientAttribute name="defaultMessageDialogContentHeight" value="150"/>  ...   Just in Time Dialog Sizing  So  what happens if you have a variety of messages that you might add and in some cases you need a small dialog and an other cases a large one? Well in that case you can re-size these dialogs just before you submit the message. Here's some example Java code: FacesContext ctx = FacesContext.getCurrentInstance();          //reset the default dialog size for this message ExtendedRenderKitService service =              Service.getRenderKitService(ctx, ExtendedRenderKitService.class); service.addScript(ctx, "resizeDefaultMessageDialog('doc1',100,50);");          FacesMessage msg = new FacesMessage("Short message"); msg.setSeverity(FacesMessage.SEVERITY_ERROR); ctx.addMessage(null, msg);  So there you have it. This technique should, at least, allow you to control the dialog sizing just enough to stop really objectionable whitespace or scrollbars. 1 Don't worry if you don't get the reference, lest's just say my kids watch too many adverts.

    Read the article

  • Change the Default Number of Rows of Tiles on the Windows 8 UI (Metro) Screen

    - by Lori Kaufman
    By default, Windows 8 automatically sets the number of rows of tiles to fit your screen, depending on your monitor size and resolution. However, you can tell Windows 8 to display a certain number of rows of tiles at all times, despite the screen resolution. To do this, we will make a change to the registry. If you are not already on the Desktop, click the Desktop tile on the Start screen. NOTE: Before making changes to the registry, be sure you back it up. We also recommend creating a restore point you can use to restore your system if something goes wrong. HTG Explains: Why Do Hard Drives Show the Wrong Capacity in Windows? Java is Insecure and Awful, It’s Time to Disable It, and Here’s How What Are the Windows A: and B: Drives Used For?

    Read the article

  • Creating user UI using Flixel

    - by Jamie Read
    I am new to game development but familiar with programming languages. I have started using Flixel and have a working Breakout game with score and lives. What I am trying to do is add a Start Screen before actually loading the game. I have a create function that adds all the game elements to the stage: override public function create():void // all game elements { How can I add this pre-load Start Screen? I'm not sure if I have to add in the code to this create function or somewhere else and what code to actually add. Eventually I would also like to add saving, loading, options and upgrades too. So any advice with that would be great. Here is my main game.as: package { import org.flixel.*; public class Game extends FlxGame { private const resolution:FlxPoint = new FlxPoint(640, 480); private const zoom:uint = 2; private const fps:uint = 60; public function Game() { super(resolution.x / zoom, resolution.y / zoom, PlayState, zoom); FlxG.flashFramerate = fps; } } } Thanks.

    Read the article

  • Do you want to become an Oracle certified Expert in WebLogic & ADF?

    - by JuergenKress
    Hands-on Bootcamps Training Roadshows FY14 free hands-on training for community members ADF & ADF Mobile Bootcamps & WebLogic Bootcamps. For all WebLogic & ADF experts, we offer 100 free vouchers worth $195 to become an Oracle certified expert. To receive a WebLogic & ADF voucher please send an e-mail with the screenshot of your WebLogic Server 12c PreSales Specialist or ADF 11g PreSales Specialist certificate to [email protected] including your Name, Company, e-mail and Country with the e-mail subject free WebLogic & ADF voucher! Or attend a local free "Test-Fest". WebLogic ADF Pre-Sales assessment (free online test) Preparation: WebLogic 12c PreSales Specialist (OPN account required – need help?) ADF 11g PreSales Specialist (OPN account required – need help?) Implementation assessment Preparation: WebLogic 12c Implementation Specialist WebLogic Bootcamp training material (Community membership required) WebLogic Knowledge Zone Overview ADF 11g Implementation Specialist ADF 11g bootcamp training material (Community membership required) ADF Knowledge Zone Overview Free vouchers are reserved for partners from Europe, Middle East and Africa. Any other countries please contact your local partner manager! Vouchers are only valid until quarter end! WebLogic Partner Community For regular information become a member in the WebLogic Partner Community please visit: http://www.oracle.com/partners/goto/wls-emea ( OPN account required). If you need support with your account please contact the Oracle Partner Business Center. Blog Twitter LinkedIn Mix Forum Wiki Technorati Tags: education,Specialization,Implementation Specialist,OPN,OOW,Oracle OpenWorld,WebLogic,WebLogic Community,Oracle,Jürgen Kress

    Read the article

  • More Animation - Self Dismissing Dialogs

    - by Duncan Mills
    In my earlier articles on animation, I discussed various slide, grow and  flip transitions for items and containers.  In this article I want to discuss a fade animation and specifically the use of fades and auto-dismissal for informational dialogs.  If you use a Mac, you may be familiar with Growl as a notification system, and the nice way that messages that are informational just fade out after a few seconds. So in this blog entry I wanted to discuss how we could make an ADF popup behave in the same way. This can be an effective way of communicating information to the user without "getting in the way" with modal alerts. This of course, has been done before, but everything I've seen previously requires something like JQuery to be in the mix when we don't really need it to be.  The solution I've put together is nice and generic and will work with either <af:panelWindow> or <af:dialog> as a the child of the popup. In terms of usage it's pretty simple to use we  just need to ensure that the popup itself has clientComponent is set to true and includes the animation JavaScript (animateFadingPopup) on a popupOpened event: <af:popup id="pop1" clientComponent="true">   <af:panelWindow title="A Fading Message...">    ...  </af:panelWindow>   <af:clientListener method="animateFadingPopup" type="popupOpened"/> </af:popup>   The popup can be invoked in the normal way using showPopupBehavior or JavaScript, no special code is required there. As a further twist you can include an additional clientAttribute called preFadeDelay to define a delay before the fade itself starts (the default is 5 seconds) . To set the delay to just 2 seconds for example: <af:popup ...>   ...   <af:clientAttribute name="preFadeDelay" value="2"/>   <af:clientListener method="animateFadingPopup" type="popupOpened"/>  </af:popup> The Animation Styles  As before, we have a couple of CSS Styles which define the animation, I've put these into the skin in my case, and, as in the other articles, I've only defined the transitions for WebKit browsers (Chrome, Safari) at the moment. In this case, the fade is timed at 5 seconds in duration. .popupFadeReset {   opacity: 1; } .popupFadeAnimate {   opacity: 0;   -webkit-transition: opacity 5s ease-in-out; } As you can see here, we are achieving the fade by simply setting the CSS opacity property. The JavaScript The final part of the puzzle is, of course, the JavaScript, there are four functions, these are generic (apart from the Style names which, if you've changed above, you'll need to reflect here): The initial function invoked from the popupOpened event,  animateFadingPopup which starts a timer and provides the initial delay before we start to fade the popup. The function that applies the fade animation to the popup - initiatePopupFade. The callback function - closeFadedPopup used to reset the style class and correctly hide the popup so that it can be invoked again and again.   A utility function - findFadeContainer, which is responsible for locating the correct child component of the popup to actually apply the style to. Function - animateFadingPopup This function, as stated is the one hooked up to the popupOpened event via a clientListener. Because of when the code is called it does not actually matter how you launch the popup, or if the popup is re-used from multiple places. All usages will get the fade behavior. /**  * Client listener which will kick off the animation to fade the dialog and register  * a callback to correctly reset the popup once the animation is complete  * @param event  */ function animateFadingPopup(event) { var fadePopup = event.getSource();   var fadeCandidate = false;   //Ensure that the popup is initially Opaque   //This handles the situation where the user has dismissed   //the popup whilst it was in the process of fading   var fadeContainer = findFadeContainer(fadePopup);   if (fadeContainer != null) {     fadeCandidate = true;     fadeContainer.setStyleClass("popupFadeReset");   }   //Only continue if we can actually fade this popup   if (fadeCandidate) {   //See if a delay has been specified     var waitTimeSeconds = event.getSource().getProperty('preFadeDelay');     //Default to 5 seconds if not supplied     if (waitTimeSeconds == undefined) {     waitTimeSeconds = 5;     }     // Now call the fade after the specified time     var fadeFunction = function () {     initiatePopupFade(fadePopup);     };     var fadeDelayTimer = setTimeout(fadeFunction, (waitTimeSeconds * 1000));   } } The things to note about this function is the initial check that we have to do to ensure that the container is currently visible and reset it's style to ensure that it is.  This is to handle the situation where the popup has begun the fade, and yet the user has still explicitly dismissed the popup before it's complete and in doing so has prevented the callback function (described later) from executing. In this particular situation the initial display of the dialog will be (apparently) missing it's normal animation but at least it becomes visible to the user (and most users will probably not notice this difference in any case). You'll notice that the style that we apply to reset the  opacity - popupFadeReset, is not applied to the popup component itself but rather the dialog or panelWindow within it. More about that in the description of the next function findFadeContainer(). Finally, assuming that we have a suitable candidate for fading, a JavaScript  timer is started using the specified preFadeDelay wait time (or 5 seconds if that was not supplied). When this timer expires then the main animation styleclass will be applied using the initiatePopupFade() function Function - findFadeContainer As a component, the <af:popup> does not support styleClass attribute, so we can't apply the animation style directly.  Instead we have to look for the container within the popup which defines the window object that can have a style attached.  This is achieved by the following code: /**  * The thing we actually fade will be the only child  * of the popup assuming that this is a dialog or window  * @param popup  * @return the component, or null if this is not valid for fading  */ function findFadeContainer(popup) { var children = popup.getDescendantComponents();   var fadeContainer = children[0];   if (fadeContainer != undefined) {   var compType = fadeContainer.getComponentType();     if (compType == "oracle.adf.RichPanelWindow" || compType == "oracle.adf.RichDialog") {     return fadeContainer;     }   }   return null; }  So what we do here is to grab the first child component of the popup and check its type. Here I decided to limit the fade behaviour to only <af:dialog> and <af:panelWindow>. This was deliberate.  If  we apply the fade to say an <af:noteWindow> you would see the text inside the balloon fade, but the balloon itself would hang around until the fade animation was over and then hide.  It would of course be possible to make the code smarter to walk up the DOM tree to find the correct <div> to apply the style to in order to hide the whole balloon, however, that means that this JavaScript would then need to have knowledge of the generated DOM structure, something which may change from release to release, and certainly something to avoid. So, all in all, I think that this is an OK restriction and frankly it's windows and dialogs that I wanted to fade anyway, not balloons and menus. You could of course extend this technique and handle the other types should you really want to. One thing to note here is the selection of the first (children[0]) child of the popup. It does not matter if there are non-visible children such as clientListener before the <af:dialog> or <af:panelWindow> within the popup, they are not included in this array, so picking the first element in this way seems to be fine, no matter what the underlying ordering is within the JSF source.  If you wanted a super-robust version of the code you might want to iterate through the children array of the popup to check for the right type, again it's up to you.  Function -  initiatePopupFade  On to the actual fading. This is actually very simple and at it's heart, just the application of the popupFadeAnimate style to the correct component and then registering a callback to execute once the fade is done. /**  * Function which will kick off the animation to fade the dialog and register  * a callback to correctly reset the popup once the animation is complete  * @param popup the popup we are animating  */ function initiatePopupFade(popup) { //Only continue if the popup has not already been dismissed    if (popup.isPopupVisible()) {   //The skin styles that define the animation      var fadeoutAnimationStyle = "popupFadeAnimate";     var fadeAnimationResetStyle = "popupFadeReset";     var fadeContainer = findFadeContainer(popup);     if (fadeContainer != null) {     var fadeContainerReal = AdfAgent.AGENT.getElementById(fadeContainer.getClientId());       //Define the callback this will correctly reset the popup once it's disappeared       var fadeCallbackFunction = function (event) {       closeFadedPopup(popup, fadeContainer, fadeAnimationResetStyle);         event.target.removeEventListener("webkitTransitionEnd", fadeCallbackFunction);       };       //Initiate the fade       fadeContainer.setStyleClass(fadeoutAnimationStyle);       //Register the callback to execute once fade is done       fadeContainerReal.addEventListener("webkitTransitionEnd", fadeCallbackFunction, false);     }   } } I've added some extra checks here though. First of all we only start the whole process if the popup is still visible. It may be that the user has closed the popup before the delay timer has finished so there is no need to start animating in that case. Again we use the findFadeContainer() function to locate the correct component to apply the style to, and additionally we grab the DOM id that represents that container.  This physical ID is required for the registration of the callback function. The closeFadedPopup() call is then registered on the callback so as to correctly close the now transparent (but still there) popup. Function -  closeFadedPopup The final function just cleans things up: /**  * Callback function to correctly cancel and reset the style in the popup  * @param popup id of the popup so we can close it properly  * @param contatiner the window / dialog within the popup to actually style  * @param resetStyle the syle that sets the opacity back to solid  */ function closeFadedPopup(popup, container, resetStyle) { container.setStyleClass(resetStyle);   popup.cancel(); }  First of all we reset the style to make the popup contents opaque again and then we cancel the popup.  This will ensure that any of your user code that is waiting for a popup cancelled event will actually get the event, additionally if you have done this as a modal window / dialog it will ensure that the glasspane is dismissed and you can interact with the UI again.  What's Next? There are several ways in which this technique could be used, I've been working on a popup here, but you could apply the same approach to in-line messages. As this code (in the popup case) is generic it will make s pretty nice declarative component and maybe, if I get time, I'll look at constructing a formal Growl component using a combination of this technique, and active data push. Also, I'm sure the above code can be improved a little too.  Specifically things like registering a popup cancelled listener to handle the style reset so that we don't loose the subtle animation that takes place when the popup is opened in that situation where the user has closed the in-fade dialog.

    Read the article

  • Add autoFill capabilities to jQuery-UI 1.8.1

    - by rockinthesixstring
    here's what I currently have, unfortunately I cannot seem to figure out how to get autoFill to work with jQuery-UI... It used to work with the straight up Autocomplete.js <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" type="text/javascript"></script> <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.1/jquery-ui.min.js" type="text/javascript"></script> <script src="http://jquery-ui.googlecode.com/svn/tags/latest/external/jquery.bgiframe-2.1.1.js" type="text/javascript"></script> <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.1/i18n/jquery-ui-i18n.min.js" type="text/javascript"></script> <script language="javascript" type="text/javascript"> var thesource = "RegionsAutoComplete.axd?PID=3" $(function () { function log(message) { $("<div/>").text(message).prependTo("#log"); $("#log").attr("scrollTop", 0); } $.expr[':'].textEquals = function (a, i, m) { return $(a).text().match("^" + m[3] + "$"); }; $("#birds").autocomplete({ source: thesource, change: function (event, ui) { //if the value of the textbox does not match a suggestion, clear its value if ($(".ui-autocomplete li:textEquals('" + $(this).val() + "')").size() == 0) { $(this).val(''); } else { log(ui.item ? ("Selected: " + ui.item.value + " aka " + ui.item.id) : "Nothing selected, input was " + this.value); } } }).live('keydown', function (e) { var keyCode = e.keyCode || e.which; //if TAB or RETURN is pressed and the text in the textbox does not match a suggestion, set the value of the textbox to the text of the first suggestion if ((keyCode == 9 || keyCode == 13) && ($(".ui-autocomplete li:textEquals('" + $(this).val() + "')").size() == 0)) { $(this).val($(".ui-autocomplete li:visible:first").text()); } }); }); </script> I've used the answer here to get the mustMatch working, but unfortunately if I "tab" away from the input box, I get the "Nothing selected" response instead of an Value and ID. Does anyone know how to extract the ID out of the autocomplete when you don't actually select the field?

    Read the article

  • How do faces in .obj work?

    - by Adl
    Hi When parsing an .obj-file, with vertices and vertex-faces, it is easy to pass the vertices to the shader and the use glDrawElements using the vertex-faces. When parsing an .obj-file, with vertices and texture-coordinates, another type of face occur: texture-coordinate faces. When displaying textures, apart from loading images, binding them and passing texture coordinates into the parser, how to use the texture-coordinate faces? They differ from the vertex-faces and I suppose that the texture-coordinate faces have a purpose when displaying textures? Regards Niclas

    Read the article

< Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >