Return-Path: X-Original-To: apmail-myfaces-dev-archive@www.apache.org Delivered-To: apmail-myfaces-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EB16CDE69 for ; Wed, 4 Jul 2012 07:52:32 +0000 (UTC) Received: (qmail 48141 invoked by uid 500); 4 Jul 2012 07:52:32 -0000 Delivered-To: apmail-myfaces-dev-archive@myfaces.apache.org Received: (qmail 47856 invoked by uid 500); 4 Jul 2012 07:52:31 -0000 Mailing-List: contact dev-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Development" Delivered-To: mailing list dev@myfaces.apache.org Received: (qmail 47802 invoked by uid 99); 4 Jul 2012 07:52:29 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 04 Jul 2012 07:52:29 +0000 X-ASF-Spam-Status: No, hits=-0.5 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of lu4242@gmail.com designates 209.85.160.53 as permitted sender) Received: from [209.85.160.53] (HELO mail-pb0-f53.google.com) (209.85.160.53) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 04 Jul 2012 07:52:23 +0000 Received: by pbbrr13 with SMTP id rr13so10306985pbb.12 for ; Wed, 04 Jul 2012 00:52:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; bh=9huzgRXWHKFiHa4VCwy69X9Hpf7N6R7ZTNp6tm8SVXU=; b=E1WAAwNWZOM2a3yvJcRYA7y6uADDqTPFr/9G2jurz3iNKGms+i9KP66NLKCAG8nxUe MJ5rTSuo2bMUG33LHDnMDsHHq1maXGdB+lKOv9z0Zi9J4BI4wxg0vs2OGaV0h1K3rwbs Ztv4NMFBeqnZuCYGpJg09wiCk+cYNLyHDm38IuNyD6bbHwt7NHYfMJ3EgYvhqIB6hLfX 5Bi2hHXYdBBZMAvQLVLe4rYZYxHmpZY3xU5oHweU9i8vB1yPAzM9ozqWJTQxA+GUMkDh N/+r7QfGi35LvIJvAIo1wnJbYnvMsKtCdNXa4KXuDbYyQS7umOG36eMVMKOV0cqT54eG da6Q== MIME-Version: 1.0 Received: by 10.68.197.198 with SMTP id iw6mr15482611pbc.36.1341388322211; Wed, 04 Jul 2012 00:52:02 -0700 (PDT) Received: by 10.142.80.16 with HTTP; Wed, 4 Jul 2012 00:52:02 -0700 (PDT) In-Reply-To: <4FF295CD.403@his.de> References: <4FED6DA2.1060308@his.de> <4FF295CD.403@his.de> Date: Wed, 4 Jul 2012 09:52:02 +0200 Message-ID: Subject: Re: disabled not working (?) From: Leonardo Uribe To: MyFaces Development Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi I have been thinking about it, and look the issue from other point of view is valid too. I have an ajax button, and I disable the ajax behavior, why the button should magically "convert" into a normal submit button. Also, there are considerations from performance perspective, because that means we should evaluate disable property for every client behavior before call the submit script code, so at the end we should evaluate twice that attribute, one to check and the second one to render the script. After the previous considerations, it sounds better let it as is. regards, Leonardo Uribe 2012/7/3 Dennis H=F6rsch : > Hi > > So, what to do next? Should I make a ticket at MyFaces? > > Greetings, > dennis > > Am 29.06.2012 15:12, schrieb Leonardo Uribe: > >> Hi >> >> Probably that's something not explicitly specified, but I think at >> first view it has sense what you say. If the client behavior is >> disabled, it should not generate any scripts, and the submit should >> work as usual. >> >> regards, >> >> Leonardo Uribe >> >> 2012/6/29 Dennis H=F6rsch: >>> >>> Hi, >>> >>> I tested to disable all temporally on my page >>> (programatically, >>> for testing reasons). >>> The behavior that I would expect is that the button then submits as >>> without >>> the f:ajax tag. >>> >>> But instead of this, the whole button is kind of disabled. This is also >>> the >>> case if I disable the f:ajax directly: >>> >>> >>> >>> >>> >>> In the HTML the button has an onclick with 'return false'. Is this the >>> desired behavior? >>> As I discovered so far this 'return false' is in the end depend on >>> AjaxBehavior.getHints(). >>> >>> "getHints(): This method returns an unmodifiable Set containing the >>> ClientBehaviorHint SUBMITTING." >>> >>> (http://javaserverfaces.java.net/nonav/docs/2.1/javadocs/javax/faces/co= mponent/behavior/AjaxBehavior.html) >>> >>> But why does the AjaxBehavior pretend to be 'SUBMITTING' while generati= ng >>> no >>> script? >>> >>> If I change it to return an empty set if it is disabled it works as >>> expected. >>> >>> Greetings >>> dennis >>> >>> -- >>> HIS Hochschul-Informations-System GmbH >>> Goseriede 9 | 30159 Hannover |www.his.de >>> >>> Dennis H=F6rsch >>> Unternehmensbereich Hochschul-IT >>> Arbeitsbereich Personalmanagement >>> Telefon +49 (0)511 1220-403 >>> E-Mailhoersch@his.de >>> >>> Registergericht: Amtsgericht Hannover, HRB 6489 >>> Gesch=E4ftsf=FChrer: Prof. Dr. Martin Leitner >>> Vorsitzender des Aufsichtsrats: Prof. Dr. Andreas Geiger >>> >>> > >